Open
Description
I´m developing an website in ROR
I am using gem 'gmaps4rails'.
In localhost the map is showed, but when i put on a production server (DigitalOcean) gives me this error: Uncaught ReferenceError: Gmaps is not defined
i have this script in my index.html.erb:
<div id="map_show" ></div>
</div>
<script type="text/javascript">
handler = Gmaps.build('Google');
handler.buildMap({ provider: {}, internal: {id: 'map_show'}}, function(){
markers = handler.addMarkers(<%=raw @hash.to_json %>);
handler.bounds.extendWith(markers);
handler.fitMapToBounds();
});
</script>
My application.js is this:
//= require jquery
//= require bootstrap-sprockets
//= require jquery_ujs
//= require turbolinks
//= require underscore
//= require gmaps/google
//= require highcharts
//= require chartkick
//= require_tree .
Anyone know how can i resolve my problem?
Metadata
Metadata
Assignees
Labels
No labels