How to Hide Search and Task View from Taskbar in Windows 10

Windows 10 comes with a Search box and a Task View button enabled on the taskbar. They take up valuable space on the taskbar. Although they look like any other regular pinned app, they have no context menu. Windows 10 users may want to hide these controls to get more room for running apps. Here is how to get rid of the Search box and the Task View button on the taskbar.