mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-12-28 12:33:08 +02:00
Create type definition for 'koa-slow' (#4072)
This commit is contained in:
parent
ce576dea8f
commit
5049870b6e
2 changed files with 15 additions and 1 deletions
14
src/@types/koa-slow.d.ts
vendored
Normal file
14
src/@types/koa-slow.d.ts
vendored
Normal file
|
@ -0,0 +1,14 @@
|
|||
declare module 'koa-slow' {
|
||||
import { Middleware } from 'koa';
|
||||
|
||||
interface ISlowOptions {
|
||||
url?: RegExp
|
||||
delay?: number
|
||||
}
|
||||
|
||||
function slow(options?: ISlowOptions): Middleware;
|
||||
|
||||
namespace slow {} // Hack
|
||||
|
||||
export = slow;
|
||||
}
|
|
@ -13,7 +13,7 @@ import * as mount from 'koa-mount';
|
|||
import * as compress from 'koa-compress';
|
||||
import * as koaLogger from 'koa-logger';
|
||||
import * as requestStats from 'request-stats';
|
||||
//const slow = require('koa-slow');
|
||||
//import * as slow from 'koa-slow';
|
||||
|
||||
import activityPub from './activitypub';
|
||||
import webFinger from './webfinger';
|
||||
|
|
Loading…
Reference in a new issue