amitdar amitdar - 6 months ago 128
Javascript Question

Creating a layer from svg image using openlayers 3

So I'm trying to take big svg file and use it as a layer on open layers 3 map. I only want to display the svg, without any map underneath it. Trying to get an answer produced some info about using icon marker for that, but I couldn't make it to work.

Does anyone know how to simply show an svg file as a layer ?


I just answered this in another similiar question. See that answer for a runnable example.

The gist of it: just include the svg file as the url for ol.source.ImageStatic.