Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@axios-use/plugins

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@axios-use/plugins

Plugins for Axios

  • 0.1.0-alpha.0
  • alpha
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

@axios-use/plugins

Plugins for Axios

Interceptors

Retry

A Axios interceptor to retry requests. Intercept AxiosError code ERR_NETWORK and ETIMEDOUT report errors, try to retry again.

import { retryInterceptorArgs } from "@axios-use/plugins";
// or
import retryInterceptorArgs from "@axios-use/plugins/retry";

axios.interceptors.response.use(...retryInterceptorArgs);
configtypedefaultexplain
retrynumber-number of retries
retryDelaynumber1000millisecond of retry delay
axios({
  method: "get",
  url: "/api/users",
  /** number of retries */
  retry: 1,
  /** millisecond of retry delay @default 1000 */
  retryDelay: 1200,
});

License

MIT

Keywords

FAQs

Package last updated on 20 Apr 2023

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc