Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: new MapControl component #51

Merged
merged 1 commit into from
Nov 6, 2023

Conversation

usefulthink
Copy link
Collaborator

@usefulthink usefulthink commented Nov 3, 2023

Adds a new component MapControl that allows users to add custom react components to the controls of a Map instance.

Example:

import {APIProvider, Map, MapControl, ControlPosition} from '@vis.gl/react-google-maps';

const App = () => (
  <APIProvider apiKey={'...'}>
    <Map {...mapProps}>
      <MapControl position={ControlPosition.TOP_LEFT}>
          .. any component here will be added to
             the control-containers of the google map instance ..
      </MapControl>
    </Map>
  </APIProvider>
);

The MapControl component allows users to add custom react components to the controls of a Map instance.
@usefulthink usefulthink merged commit 7eb49ed into visgl:main Nov 6, 2023
2 checks passed
@usefulthink usefulthink deleted the feat/map-control branch November 6, 2023 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants