October 2019
Intermediate to advanced
426 pages
11h 49m
English
A more powerful way of dealing with requests, is using the axios and react-request-hook libraries. Using these libraries, we have access to features that can cancel a single request, or even clear all pending requests. Furthermore, using these libraries makes it easier to deal with errors and loading states.
We are now going to implement the useResource Hook in order to request themes from our server:
import { useResource } from 'react-request-hook'
Read now
Unlock full access