Skip to content

useApiLoadingStatus

useApiLoadingStatus hooks is used for get current LoadingStatus.

In most cases, you won’t need to use it.

Basic Example

function App() {
const loadingStatus = useApiLoadingStatus();
return (
<GoogleMapApiLoader
apiKey='YOUR_API_KEY'
>
{
loadingStatus === LoadingStatus.SUCCESS && (
// now you can use Google Map API.
<MyMap />
)
}
</GoogleMapApiLoader>
);
}