javascript - polyline in rails using js -


i'm trying draw simple polylines in js (rails) ain't showing anything.

function drawlines() {     var flightpath = new google.maps.polyline({     path: flightplancoordinates,     geodesic: true,     strokecolor: '#ff0000',     strokeopacity: 1.0,     strokeweight: 25,     map:map     });  flightpath.setmap(map); console.log('drawn'); } 

i suggest code. in code, don't need use settings map:map.

try code

function drawlines(){          var flightpath = new google.maps.polyline({           path: flightplancoordinates,           geodesic: true,           strokecolor: '#ff0000',           strokeopacity: 1.0,           strokeweight: 25,          });         flightpath.setmap(map); } 

Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

reflection - How to access the object-members of an object declaration in kotlin -

php - Doctrine Query Builder Error on Join: [Syntax Error] line 0, col 87: Error: Expected Literal, got 'JOIN' -