New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

react-cache-request

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-cache-request

一个简易使用axios网络请求的hook,自带状态管理,缓存功能

latest
Source
npmnpm
Version
0.3.0
Version published
Maintainers
1
Created
Source

react-cache-request

一个使用axios进行网络请求的hook函数,具备内存,磁盘缓存功能。支持react,react-native

Getting Started

Install

$ yarn add react-cache-request axios

Usage

Import

import {useRequest} from 'react-cache-request';

Simple use


 const {data, status, error} = useRequest({url: 'https://cnodejs.org/api/v1/topics'})

Docs

文档

Example

项目中有react和react-native的示例

Issue

觉得不错的小手一点,给个star,有遇到什么bug或者有什么建议的欢迎提issue

License

MIT

Keywords

react-hooks

FAQs

Package last updated on 09 Apr 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts