1.9.0 • Published 8 months ago

react-gmaps v1.9.0

Weekly downloads
1,255
License
MIT
Repository
github
Last release
8 months ago

MarkerPolylinePolygon
npm.ionpm.ionpm.io
const location = { lat: 40.73061, lng: -73.935242 };

function MyMarker() {
  return (
    <GMapsMarker location={location}>
      <p style={{ backgroundColor: "red" }}>Hello World</p>
    </GMapsMarker>
  );
}

function MyMap() {
  return (
    <div style={{ height: "100vh" }}>
      <GMaps center={location} zoom={12}>
        <MyMarker />
      </GMaps>
    </div>
  );
}

Features

  • Marker, Polyline, Polygon components and more
  • Hook based
  • Highly extensible
  • Interpolation animations for everything (markers, polygons, etc.)

Documentation

See our documentation

Why yet another Google Maps integration for ReactJS?

Why choose React GMaps when there's already react-google-maps-api, google-maps-react, google-map-react, etc. ? The current landscape doesn't really provide a smooth integration for GoogleMaps in a ReactJS application with hooks and modern patterns. Existing implementations tends to be old/unmaintained, outdated, lacking features, and/or a bit wobbly.

React GMaps aims to be more flexible, extensible, and composable by exposing simple primitives that can be used in various ways. It utilizes modern GoogleMaps features such as AdvancedMarkers to avoid wacky hacks and unstable integrations. Plus its context base architecture, enables users to easly access GMaps functionalities programmaticaly and create GoogleMaps related libraries for others to use (similarly to the built-in Animated components).

TODOs

Wanna help? See our contributing.md.

  • Marker component (displays ReactJS components)
  • LegacyMarker component (displays images only)
  • Polyline component
  • Polygon component
  • Circle component
  • Rectangle component
  • Overlays
  • Hooks to access the google sdk and google.maps.Map instance using a ref to <GMaps />
2.0.0-next.0

8 months ago

1.9.0

6 years ago

1.8.0

6 years ago

1.7.0

7 years ago

1.6.0

7 years ago

1.5.0

8 years ago

2.0.0-rc4

8 years ago

2.0.0-rc3

8 years ago

2.0.0-rc2

8 years ago

2.0.0-rc1

8 years ago

1.4.4

8 years ago

1.4.3

8 years ago

1.4.2

8 years ago

1.4.1

8 years ago

1.4.0

8 years ago

1.3.0

8 years ago

1.2.2

8 years ago

1.2.1

8 years ago

1.2.0

8 years ago

1.1.0

8 years ago

1.0.4

9 years ago

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

0.4.2

9 years ago

0.4.1

9 years ago

0.4.0

9 years ago

0.3.4

9 years ago

0.3.3

9 years ago

0.3.2

9 years ago

0.3.1

9 years ago

0.3.0

9 years ago

0.2.0

9 years ago

0.1.13

9 years ago

0.1.12

9 years ago

0.1.11

9 years ago

0.1.10

9 years ago

0.1.9

9 years ago

0.1.8

9 years ago

0.1.7

9 years ago

0.1.6

9 years ago

0.1.5

9 years ago

0.1.4

9 years ago

0.1.3

9 years ago

0.1.2

9 years ago

0.1.1

9 years ago

0.1.0

9 years ago

1.0.0

9 years ago