mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-28 16:45:10 +08:00
15 lines
275 B
TypeScript
15 lines
275 B
TypeScript
|
|
|
|
import compose = require('koa-compose');
|
|
|
|
var fn1: compose.Middleware = function *(next: void) {
|
|
console.log('in fn1');
|
|
yield next;
|
|
}
|
|
|
|
var fn2: compose.Middleware = function *(next: void) {
|
|
console.log('in fn2');
|
|
yield next;
|
|
}
|
|
|
|
var fn = compose([fn1, fn2]); |