I'm using Leaflet.js the leaflet-js' gem, but can't figure out the syntax to get the map to show.
<div id="map">
<%=
var map = L.map('map').setView([-41.2858, 174.78682], 14);
mapLink =
'<a href="http://openstreetmap.org">OpenStreetMap</a>';
L.tileLayer(
'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
attribution: 'Map data © ' + mapLink,
maxZoom: 18,
}).addTo(map);
%>
</div>
produces the error uninitialized constant ActionView::CompiledTemplates::L. What is the correct formatting and is there a guide on how to translate regular javascript for use with Rails? Thank you for any help.