# react-google-places-autocomplete

> Google places autocomplete input for ReactJS.

Latest version **4.1.0** (published 2024-08-26) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-google-places-autocomplete
pnpm add react-google-places-autocomplete
yarn add react-google-places-autocomplete
bun add react-google-places-autocomplete
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 4.1.0 |
| Published | 2024-08-26 |
| First published | 2019-01-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 4 |
| Unpacked size | 1.4 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 380 |
| Author | Nicolás Tinte |
| Maintainers | tintef |
| Keywords | react, google-places, places, autocomplete |

## Links

- npm: https://www.npmjs.com/package/react-google-places-autocomplete
- Repository: https://github.com/Tintef/react-google-places-autocomplete
- Homepage: https://github.com/Tintef/react-google-places-autocomplete#readme
- Issues: https://github.com/Tintef/react-google-places-autocomplete/issues
- npm.io page: https://npm.io/package/react-google-places-autocomplete

## Dependencies (4)

- [react-select](https://npm.io/package/react-select.md) ^5.7.4
- [use-debounce](https://npm.io/package/use-debounce.md) ^3.4.3
- [@types/google.maps](https://npm.io/package/@types/google.maps.md) ^3.50.4
- [@googlemaps/js-api-loader](https://npm.io/package/@googlemaps/js-api-loader.md) ^1.14.3

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 4.1.0 (latest) — 2024-08-26
- 2.3.0-beta.1 (beta) — 2020-07-27
- 2.0.0-alpha.1 (alpha) — 2020-02-03
- 4.0.1 — 2023-04-17
- 4.0.0 — 2023-04-16
- 3.4.0 — 2022-07-04
- 3.3.4 — 2022-02-22
- 3.3.3 — 2022-02-21
- 3.3.2 — 2021-08-16
- 3.3.2-alpha.0 — 2021-07-18
- 3.3.1 — 2021-05-11
- 3.3.0 — 2021-03-14
- 3.2.4 — 2021-03-13
- 3.2.3 — 2021-03-09
- 3.2.2 — 2021-03-05
- … 46 more at https://npm.io/package/react-google-places-autocomplete/versions

## README

<p align="center">
  <a href="https://tintef.github.io/react-google-places-autocomplete" target="_blank">
    <img width="250"src="https://raw.githubusercontent.com/tintef/react-google-places-autocomplete/master/docs/static/img/logo.svg">
  </a>
</p>

<p align="center">
  <a href="https://www.npmjs.com/package/react-google-places-autocomplete">
    <img src="https://img.shields.io/npm/v/react-google-places-autocomplete.svg"/>
    <img src="https://img.shields.io/npm/dm/react-google-places-autocomplete.svg"/>
  </a>
  <a href="https://travis-ci.org/tintef/react-google-places-autocomplete">
    <img src="https://www.travis-ci.com/Tintef/react-google-places-autocomplete.svg?branch=master" />
  </a>
  <a href="https://packagequality.com/#?package=react-google-places-autocomplete">
    <img src="https://npm.packagequality.com/shield/react-google-places-autocomplete.svg"/>
  </a>
  <a href="https://www.npmjs.com/package/react-google-places-autocomplete">
    <img src="https://img.shields.io/npm/l/react-google-places-autocomplete.svg" alt="License">
  </a>
</p>


# React Google Places Autocomplete

React component for easily use Google Places Autocomplete


## Getting started

Install the latest version:
```sh
npm install --save react-google-places-autocomplete
  or
yarn add react-google-places-autocomplete
```

Use the component!
```js
import React from 'react';
import GooglePlacesAutocomplete from 'react-google-places-autocomplete';

const Component = () => (
  <div>
    <GooglePlacesAutocomplete
      apiKey="****"
    />
  </div>
);

export default Component;
```

**Coming from v2? Check the [migration guide](https://tintef.github.io/react-google-places-autocomplete/docs/v2-to-v3)**

## Documentation

[**Read The Docs**](https://tintef.github.io/react-google-places-autocomplete)

## How to contribute?

1. Fork this repo
2. Clone your fork
3. Code 🤓
4. Test your changes

    For this, I like to use [yalc](https://github.com/whitecolor/yalc), as it allows to emulate the process of using npm/yarn.

    1. Install [yalc](https://github.com/whitecolor/yalc)
    2. Build project with `yarn build` or `npm run build`
    3. Publish the package with yalc: `yalc publish`
    4. Add the package to your test project `yalc add react-google-places-automocomplete`
    5. If needed, to update the package on your test project: `yalc update react-google-places-autocomplete`


5. Submit a PR!


<br />
<br />
<p align="center">
  Icons made by <a href="https://www.flaticon.com/authors/freepik" title="Freepik">Freepik</a> from <a href="https://www.flaticon.com/" title="Flaticon">www.flaticon.com</a>
</p>

---
_Source: https://npm.io/package/react-google-places-autocomplete · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
