danielemoraschi / maplace.js

A Google Maps Javascript plugin for jQuery.
http://maplacejs.com/
MIT License
999 stars 190 forks source link

Geojson loading data #188

Open dkedar opened 5 years ago

dkedar commented 5 years ago

I want to display locations from Geojson or Json external file on the map with mplace plugin. something like Google Maps Platform, for example please check below code, How to?

map.data.loadGeoJson(
      'https://storage.googleapis.com/mapsdevsite/json/google.json');
}

Thanks

lcherone commented 1 year ago

For example, if you did: const map = new Maplace(...)

The map instance, i.e new window.google.maps.Map is placed in map.oMap, so you would do:

map.oMap.data.loadGeoJson('https://storage.googleapis.com/mapsdevsite/json/google.json')