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 -

performance - Why is XCHG reg, reg a 3 micro-op instruction on modern Intel architectures? -

jquery - Responsive Navbar with Sub Navbar -