DefinitelyTyped/types/koa-mount/index.d.ts
Vladislav Polyakov 4070665056 Add generic support for [@types/koa-mount] (#36365)
* Add generic support

* fix: lint errors

* fix: unnecessary semicolon

* feat: add generic types in overload
2019-06-27 10:49:21 -07:00

23 lines
766 B
TypeScript

// Type definitions for koa-mount 4.0
// Project: https://github.com/koajs/mount
// Definitions by: AmirSaber Sharifi <https://github.com/amirsaber>
// Tomek Łaziuk <https://github.com/tlaziuk>
// Vladislav Polyakov <https://github.com/polrk>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.3
import Koa = require("koa");
declare function mount<StateT = any, CustomT = {}>(
app: Koa.Middleware<StateT, CustomT> | Koa<StateT, CustomT>
): Koa.Middleware<StateT, CustomT>;
declare function mount<StateT = any, CustomT = {}>(
prefix: string,
app: Koa.Middleware<StateT, CustomT> | Koa<StateT, CustomT>
): Koa.Middleware<StateT, CustomT>;
declare namespace mount { }
export = mount;