diff --git a/examples/lazy-source.html b/examples/lazy-source.html new file mode 100644 index 0000000000..ce57a051d5 --- /dev/null +++ b/examples/lazy-source.html @@ -0,0 +1,73 @@ + + +
+ + + + + + + +Example of setting a layer source after construction.
+
+ Typically, the source for a layer is provided to the layer constructor.
+ If you need to set a layer source after construction, this can be
+ done with the layer.setSource() method.
+
+ The layer in the map above is constructed with no source. Use the + links below to set/unset the layer source. A layer is not rendered + until its source is set. +
++ + +
+See the lazy-source.js source for details on how this is done.
+