Socket
Socket
Sign inDemoInstall

koa-simple-ratelimit

Package Overview
Dependencies
Maintainers
2
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

koa-simple-ratelimit - npm Package Compare versions

Comparing version 3.1.0 to 4.0.0

6

dist/index.d.ts

@@ -1,5 +0,1 @@

/**
* Expose `ratelimit()`
*/
export default ratelimit;
export declare type RatelimitExpires = (expires: number) => string;

@@ -64,2 +60,2 @@ export interface RatelimitOptions {

*/
declare function ratelimit(options: RatelimitOptions): (ctx: any, next: any) => Promise<any>;
export declare function ratelimit(options: RatelimitOptions): (ctx: any, next: any) => Promise<any>;

@@ -31,7 +31,2 @@ "use strict";

/**
* Expose `ratelimit()`
*/
exports.default = ratelimit;
module.exports = ratelimit;
/**
* Initialize ratelimit middleware with the given `opts`

@@ -107,2 +102,3 @@ */

}
exports.ratelimit = ratelimit;
//# sourceMappingURL=index.js.map

18

package.json
{
"name": "koa-simple-ratelimit",
"version": "3.1.0",
"version": "4.0.0",
"description": "Simple Rate limiter middleware for koa v2",

@@ -38,12 +38,12 @@ "repository": "scttcper/koa-simple-ratelimit",

"@types/koa": "2.0.49",
"@types/node": "12.7.3",
"@types/node": "12.7.5",
"@types/redis": "2.8.13",
"@types/supertest": "2.0.8",
"@typescript-eslint/eslint-plugin": "2.0.0",
"@typescript-eslint/parser": "2.0.0",
"eslint": "6.3.0",
"@typescript-eslint/eslint-plugin": "2.3.0",
"@typescript-eslint/parser": "2.3.0",
"eslint": "6.4.0",
"eslint-config-xo-space": "0.21.0",
"eslint-config-xo-typescript": "0.17.0",
"eslint-config-xo-typescript": "0.18.0",
"eslint-plugin-import": "2.18.2",
"ioredis": "^4.14.0",
"ioredis": "^4.14.1",
"jest": "24.9.0",

@@ -55,4 +55,4 @@ "jest-junit": "8.0.0",

"supertest": "4.0.2",
"ts-jest": "24.0.2",
"typescript": "3.6.2"
"ts-jest": "24.1.0",
"typescript": "3.6.3"
},

@@ -59,0 +59,0 @@ "jest": {

@@ -28,3 +28,3 @@ # koa-simple-ratelimit

import ratelimit from './src';
import { ratelimit } from 'koa-simple-ratelimit';

@@ -31,0 +31,0 @@ const app = new Koa();

Sorry, the diff of this file is not supported yet

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