mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
[@types/koa-html-minifier] Add type definitions (#27691)
* Add koa-router's Router to koa's Context * [@types/koa-html-minifier] Add type definitions * Fix incorrect TypeScript version
This commit is contained in:
parent
f20b7f5323
commit
bb6b63a59b
14
types/koa-html-minifier/index.d.ts
vendored
Normal file
14
types/koa-html-minifier/index.d.ts
vendored
Normal file
@ -0,0 +1,14 @@
|
||||
// Type definitions for koa-html-minifier 1.0
|
||||
// Project: https://github.com/koajs/html-minifier
|
||||
// Definitions by: Romain Faust <https://github.com/romain-faust>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.3
|
||||
|
||||
import { Middleware } from 'koa';
|
||||
import { Options } from 'html-minifier';
|
||||
|
||||
declare function minifier(options?: Options): Middleware;
|
||||
|
||||
declare namespace minifier {}
|
||||
|
||||
export = minifier;
|
||||
8
types/koa-html-minifier/koa-html-minifier-tests.ts
Normal file
8
types/koa-html-minifier/koa-html-minifier-tests.ts
Normal file
@ -0,0 +1,8 @@
|
||||
import * as Koa from 'koa';
|
||||
import * as KoaHtmlMinifier from 'koa-html-minifier';
|
||||
|
||||
const app = new Koa()
|
||||
.use(KoaHtmlMinifier())
|
||||
.use(KoaHtmlMinifier({
|
||||
collapseWhitespace: true
|
||||
}));
|
||||
23
types/koa-html-minifier/tsconfig.json
Normal file
23
types/koa-html-minifier/tsconfig.json
Normal file
@ -0,0 +1,23 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"koa-html-minifier-tests.ts"
|
||||
]
|
||||
}
|
||||
1
types/koa-html-minifier/tslint.json
Normal file
1
types/koa-html-minifier/tslint.json
Normal file
@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Loading…
Reference in New Issue
Block a user