Skip to content
zenui/react-hooks

useFetch

Fetch JSON from a URL and track data, loading and error. It aborts stale requests when the URL changes or the component unmounts, and can refetch on demand.

Level
Intermediate
Since
v1.0.0
import {useFetch} from '@zenuilabs/react-hooks';
Loading demo_

More in Async & Data