All Projects → aishek → Axios Rate Limit

aishek / Axios Rate Limit

Licence: mit
Rate limit for axios

Programming Languages

javascript
184084 projects - #8 most used programming language
typescript
32286 projects
js
455 projects

Projects that are alternatives of or similar to Axios Rate Limit

Reactjs Spring Boot Crud Full Stack App
Learn how to develop a full-stack CRUD application using React as frontend and spring boot as backend.
Stars: ✭ 90 (-15.09%)
Mutual labels:  axios
Vuedemo sell eleme
ele by vue2.x 🐧
Stars: ✭ 1,349 (+1172.64%)
Mutual labels:  axios
Seppf
普兰能效平台开源版(前端)
Stars: ✭ 104 (-1.89%)
Mutual labels:  axios
Xyy Vue
🎨基于vue+vue-router+vuex+axios+webpack开发的个人Demo《Qu约》
Stars: ✭ 1,316 (+1141.51%)
Mutual labels:  axios
Eagles
eagles for vue componets of silianpan
Stars: ✭ 95 (-10.38%)
Mutual labels:  axios
Django Auth0 Vue
A Django REST Framework + Vue.js CRUD Demo Secured Using Auth0
Stars: ✭ 99 (-6.6%)
Mutual labels:  axios
Sentinel Cpp
C++ implementation of Sentinel
Stars: ✭ 91 (-14.15%)
Mutual labels:  rate-limiting
Wepy Plugin Axios
在 wepy 中使用 axios
Stars: ✭ 105 (-0.94%)
Mutual labels:  axios
Fontend
使用Node、Vue、ElementUI、iViewUI,验证码等等搭建一个综合性网站(含后台管理系统)
Stars: ✭ 97 (-8.49%)
Mutual labels:  axios
React Bootstrap Webpack Starter
ReactJS 16.4 + new React Context API +react Router 4 + webpack 4 + babel 7+ hot Reload + Bootstrap 4 + styled-components
Stars: ✭ 103 (-2.83%)
Mutual labels:  axios
Naice Blog
😺 新的博客上线啦
Stars: ✭ 93 (-12.26%)
Mutual labels:  axios
Gitdatav
基于Vue框架构建的github数据可视化平台
Stars: ✭ 1,328 (+1152.83%)
Mutual labels:  axios
Myxhr
TypeScript 重构 Axios 经验分享,包括开发技巧, API 实现,XMLHttpRequest 运用,单元测试等
Stars: ✭ 102 (-3.77%)
Mutual labels:  axios
Taro Axios
在 Taro 中使用 axios。
Stars: ✭ 92 (-13.21%)
Mutual labels:  axios
Ashen Blog
使用koa 2 + vue 2搭建自己的博客系统
Stars: ✭ 104 (-1.89%)
Mutual labels:  axios
Spala
Spala (SPA LARAVEL): a modern lightweight CMS for Laravel and Vue developers (open source project).
Stars: ✭ 91 (-14.15%)
Mutual labels:  axios
Governor
A rate-limiting library for Rust (formerly ratelimit_meter)
Stars: ✭ 99 (-6.6%)
Mutual labels:  rate-limiting
Request
go request, go http client
Stars: ✭ 105 (-0.94%)
Mutual labels:  axios
Iview Vue Admin
iView vue Admin / An admin management system template
Stars: ✭ 105 (-0.94%)
Mutual labels:  axios
Vue2 Shop
A shop developed with Vue2 + Vue-router + Axios + Vuex + Node + Express + MongoDB + Webpack
Stars: ✭ 103 (-2.83%)
Mutual labels:  axios

axios-rate-limit

npm version npm downloads Build Status

A rate limit for axios: set how many requests per interval should perform immediately, other will be delayed automatically.

Installing

yarn add axios-rate-limit

Usage

import axios from 'axios';
import rateLimit from 'axios-rate-limit';

// sets max 2 requests per 1 second, other will be delayed
// note maxRPS is a shorthand for perMilliseconds: 1000, and it takes precedence
// if specified both with maxRequests and perMilliseconds
const http = rateLimit(axios.create(), { maxRequests: 2, perMilliseconds: 1000, maxRPS: 2 })
http.getMaxRPS() // 2
http.get('https://example.com/api/v1/users.json?page=1') // will perform immediately
http.get('https://example.com/api/v1/users.json?page=2') // will perform immediately
http.get('https://example.com/api/v1/users.json?page=3') // will perform after 1 second from the first one

// options hot-reloading also available
http.setMaxRPS(3)
http.getMaxRPS() // 3
http.setRateLimitOptions({ maxRequests: 6, perMilliseconds: 150 }) // same options as constructor
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].