1.0.0 • Published 7 months ago

axios-throttle-interceptor v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
7 months ago

axios-throttle-interceptor

CI NPM Version MIT License Install Size

📦 Installation

npm install axios-throttle-interceptor axios

🚀 Usage

import axios from 'axios';
import axiosThrottle from 'axios-throttle-interceptor';

const instance = axios.create();

axiosThrottle(instance, {
  limit: 5,
  interval: 1000,
  onDelay: () => console.log('Request delayed due to throttling.'),
});

instance.get('...'); // The requests are now throttled.

🤝 Contributing

Want to contribute? Awesome! To show your support is to star the project, or to raise issues on GitHub

Thanks again for your support, it is much appreciated! 🙏

License

MIT © Shahrad Elahi

1.0.0

7 months ago