Skip to content

Commit ebde5d1

Browse files
committed
2 parents 0408fa4 + 58fea0b commit ebde5d1

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,20 @@ Lazy Loading of Google Maps Javascript
7676
map-lazy-load-params="{{googleMapsUrl}}">
7777
<ng-map center="41,-87" zoom="3"></ng-map>
7878
</div>
79+
80+
FAQ
81+
----
82+
## Grey area in Google maps
83+
84+
The usual reason why this is happening is that the size of the map is changed after the map has been initialized. If you for some reason change the size of the div, you need to trigger the "resize" event and possible reCenter the map.
85+
86+
var center = map.getCenter();
87+
google.maps.event.trigger(map, "resize");
88+
map.setCenter(center);
89+
90+
Ref.
91+
* http://stackoverflow.com/questions/13901520/grey-area-in-google-maps
92+
* http://blog.codebusters.pl/en/google-maps-in-hidden-div/
7993

8094
Directives
8195
----------

0 commit comments

Comments
 (0)