Using Marker bindTo method
See original GitHub issueI’d like to bind a Circle
to a Marker
so it follows the marker around.
How can I do this in react-google-maps?
See https://stackoverflow.com/questions/825794/draw-radius-around-a-point-in-google-map
Issue Analytics
- State:
- Created 6 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
bindTo - How do I link a marker position to the ...
bindTo - How do I link a marker position to the position of a polyline node? ... MVCObject with methods like getAt(integer) and...
Read more >Using bindTo() cannot delete marker in new position
Show activity on this post. I am using bindTo() I found this example here Bind Marker with polygon vertices google mapv3 ,but the...
Read more >Marker | Maps JavaScript API
Creates a marker with the options specified. If a map is specified, the marker is added to the map upon construction. Note that...
Read more >Marker | Google Maps JavaScript API v3 Utilities
Defined in packages/jest-mocks/src/marker.ts:21 ... bindTo: Mock<any, any> = jest.fn().mockImplementation((key: string,target: MVCObject,targetKey?: string ...
Read more >Google Maps - Additional overlay types · GEOG5870/1M
These draw a map with a set of markers representing (a subset of) ... binding the circle to the marker, using the bindTo()...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
It works! Here’s the gist: https://gist.github.com/krabbypattified/63ce708b414cfc5ea7aced3833b5c33e
@krabbypattified check the
InfoWindow
source code, in there we can access the instance ofgoogle.maps.Marker
from the context (since we put it as a child ofMarker
). Applying the same trick forCircle
, we can callcircle.bindTo('center', marker, 'position')
in any lifecycle method that’s applicable.