Chapter 3. Working with Layers

Now that we have learned the basics of creating a frame for our custom WebGIS client, we will proceed to build a fully operational layer tree. Through out the chapter, we will revise how to manage the layer stack of OpenLayers 3 and utilize these capabilities in our application.

In this chapter, we will cover the following topics:

  • Adding and removing layers dynamically
  • Adding layers with the HTML5 File API
  • Changing layer attributes based on user input
  • Changing the order of a layer with the HTML5 Drag and Drop API

Before getting started

In the previous chapters, we discussed the HTML and CSS parts quite thoroughly. From now on, we will focus on the JavaScript part of the application. We will use native JavaScript (no jQuery, ...

Get Mastering OpenLayers 3 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.