Hi all,
I just learned using Phoenix framework for couple of days.
I already:
- successfully create a new page called /maps
- the page can be loaded
- tried to put leaflet.js and leaflet.css inside web/static/vendor
- create a div and script to call leaflet map in web/templates/maps/index.html.eex
However when I load the page the map was not loaded with console says : Uncaught ReferenceError: L is not defined
It seems that the JS was not loaded but if I checked the sources using Chrome inspect element the JS was already loaded.
Am I missing something here? Any help would be appreciated.
Thanks