1.0.3 • Published 1 year ago
react-http-hook v1.0.3
React-http-hook
Installation
write this command line to install the package
npm install react-http-hook
Useage
import {createHttpHook} from 'react-http-hook'
export default const useHttp = createHttpHook({
baseUrl:string,
defaultApplyError:(error:any) => void,
getToken:() => string,
refreshToken:(response:Response) => void,
logout:() => void
});
export default useHttp;