# @types/react-google-places-suggest

> TypeScript definitions for react-google-places-suggest

Latest version **3.12.0** (published 2025-01-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install @types/react-google-places-suggest
pnpm add @types/react-google-places-suggest
yarn add @types/react-google-places-suggest
bun add @types/react-google-places-suggest
```

## Health

**Score 55/100 (C)** — status: stable.

Positive: has types; no vulnerabilities; high maintenance score; popular repo; extremely popular.

Warnings: low downloads; no esm support.

Negative: stale.

## Facts

| | |
|---|---|
| Version | 3.12.0 |
| Published | 2025-01-16 |
| First published | 2018-05-08 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 7.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51448 |
| Maintainers | types |

## Links

- npm: https://www.npmjs.com/package/@types/react-google-places-suggest
- Repository: https://github.com/DefinitelyTyped/DefinitelyTyped
- Homepage: https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-google-places-suggest
- npm.io page: https://npm.io/package/@types/react-google-places-suggest

## Dependencies (2)

- [@types/react](https://npm.io/package/@types/react.md) *
- [@types/google.maps](https://npm.io/package/@types/google.maps.md) *

## Recent versions

- 3.12.0 (latest) — 2025-01-16
- 3.4.11 (ts4.8) — 2023-12-05
- 3.4.10 (ts4.5) — 2023-11-21
- 3.4.6 (ts4.2) — 2021-12-24
- 3.4.5 (ts3.6) — 2021-07-08
- 3.4.4 (ts3.5) — 2021-05-18
- 3.4.3 (ts3.4) — 2020-09-17
- 3.4.2 (ts2.8) — 2019-02-13
- 3.4.0 (ts2.6) — 2018-05-08
- 3.4.9 — 2023-11-07
- 3.4.8 — 2023-10-18
- 3.4.7 — 2023-09-27
- 3.4.1 — 2018-08-04

## README

# Installation
> `npm install --save @types/react-google-places-suggest`

# Summary
This package contains type definitions for react-google-places-suggest (https://github.com/xuopled/react-google-places-suggest).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-google-places-suggest.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-google-places-suggest/index.d.ts)
````ts
/// <reference types="google.maps" />

import { Component, JSX, ReactNode } from "react";

declare class ReactGooglePlacesSuggest extends Component<ReactGooglePlacesSuggest.Props> {}

declare namespace ReactGooglePlacesSuggest {
    type AutocompletionRequest = google.maps.places.AutocompletionRequest;
    type PlacesServiceStatus = google.maps.places.PlacesServiceStatus;
    type Prediction = google.maps.places.AutocompletePrediction;
    type GoogleMaps = typeof google.maps;
    type GeocodedPrediction = google.maps.GeocoderResult;

    interface Props {
        /** Undocumented */
        autocompletionRequest: AutocompletionRequest;

        /** Undocumented */
        children: ReactNode;

        /** injected by react-google-maps-loader */
        googleMaps: GoogleMaps;

        /** Handle no results when enter key is pressed */
        onNoResult?:
            | (
                (
                    geocodedPrediction: GeocodedPrediction,
                    originalPrediction: Prediction,
                ) => void
            )
            | undefined;

        /** Handle click on suggest */
        onSelectSuggest?:
            | (
                (
                    geocodedPrediction: GeocodedPrediction,
                    originalPrediction: Prediction,
                ) => void
            )
            | undefined;

        /** Handle places service status update */
        onStatusUpdate?: ((status: PlacesServiceStatus) => void) | undefined;

        /** Customize list item */
        customRender?: ((prediction?: Prediction) => JSX.Element | string) | undefined;

        /** Customize list */
        customContainerRender?: ((predictions: Prediction[]) => JSX.Element | string) | undefined;

        /**
         * Display the "Powered By Google" logo as required by the [Google Maps autocomplete terms and conditions](https://developers.google.com/maps/documentation/javascript/place-autocomplete#fig1).
         * (defaults to true. Not included when using customContainerRender prop)
         *
         * @default true
         */
        displayPoweredByGoogle?: boolean;

        /**
         * No results text, null to disable
         *
         * @default "No results"
         */
        textNoResults?: string | null | undefined;
    }
}

export = ReactGooglePlacesSuggest;

````

### Additional Details
 * Last updated: Thu, 16 Jan 2025 00:46:49 GMT
 * Dependencies: [@types/google.maps](https://npmjs.com/package/@types/google.maps), [@types/react](https://npmjs.com/package/@types/react)

# Credits
These definitions were written by .

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