google-maps-js-api-react
Version:
Fast, tree-shakable, and light-weight React components and hooks for integrating Google Maps API functionality
16 lines (12 loc) • 655 B
text/typescript
/// <reference types="google.maps" />
import * as google_maps_js_api_loader from 'google-maps-js-api-loader';
/**
* Hook for loading google maps script or specific library/libraries
* > Works only for [Suspense](https://react.dev/reference/react/Suspense) wrapped components
*/
declare const useGoogleMapsLoad: {
(): void;
<L extends google_maps_js_api_loader.GoogleMapsLibrary>(library: L): google_maps_js_api_loader.GoogleMapsLibraries[L];
<const A extends google_maps_js_api_loader.GoogleMapsLibrary[]>(...libraries: A): { [Index in keyof A]: google_maps_js_api_loader.GoogleMapsLibraries[A[Index]]; };
};
export = useGoogleMapsLoad;