Skip to content

Commit

Permalink
docs: refine advanced marker docs
Browse files Browse the repository at this point in the history
  • Loading branch information
mrMetalWood committed Sep 5, 2024
1 parent a29fdeb commit d37d828
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docs/api-reference/components/advanced-marker.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ element.

When custom html is specified, the marker will be positioned such that the
`position` on the map is at the bottom center of the content-element.
If you need it positioned differently, you can use css-transforms on
the content element. For example, to have the anchor point in the top-left
corner of the marker (the transform can also be applied via a css class and
specified as `className`):
If you need it positioned differently, you can use the [`anchorPoint`](#anchorpoint-advancedmarkeranchorpoint--string-string) property of the `AdvancedMarker`. For example, to have the anchor point in the top-left
corner of the marker:

```tsx
<AdvancedMarker position={...} style={{transform: 'translate(50%, 100%)'}}>
import {AdvancedMarker, AdvancedMarkerAnchorPoint} from '@vis.gl/react-google-maps';

<AdvancedMarker position={...} anchorPoint={AdvancedMarkerAnchorPoint.TOP_LEFT}>
...
</AdvancedMarker>
```
Expand Down

0 comments on commit d37d828

Please sign in to comment.