So far, we've taken for granted that the map will move when we drag it. Or that we can just click a layer in the layer switcher and it will turn on or off. Or that we can zoom in and out. We haven't yet talked much about what actually is behind the map interaction or how it works.
Simply put, the OpenLayers Control class is what makes our maps interactive. There are many built in controls, each with their own unique functions. But, not only do you have a large number of pre-made controls at your disposal, you also have the ability to easily create your own controls.
In this chapter, we'll cover: