Here I have the map_canvas
within a div
called map
. The thing is when I increase the width
of the map
, the
Have you checked that the width of the div container has been set? Also, has the width of the map been set in the mapOptions object?
If you provide more examples of your code, it will be easier to help.
The width of the map-area is increasing but the right side of the map is not rendering fully.
When you change the size of the div, trigger the resize event on the map:
from the documentation:
Events
resize - Developers should trigger this event on the map when the div changes size: google.maps.event.trigger(map, 'resize') .