mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-06-06 06:19:58 +08:00
Merge pull request #18986 from BendingBender/compressible
[compressible] add typings
This commit is contained in:
5
types/compressible/compressible-tests.ts
Normal file
5
types/compressible/compressible-tests.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
import compressible = require('compressible');
|
||||
|
||||
// $ExpectType boolean | undefined
|
||||
compressible('text/html');
|
||||
compressible('image/png');
|
||||
8
types/compressible/index.d.ts
vendored
Normal file
8
types/compressible/index.d.ts
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
// Type definitions for compressible 2.0
|
||||
// Project: https://github.com/jshttp/compressible#readme
|
||||
// Definitions by: BendingBender <https://github.com/BendingBender>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
export = compressible;
|
||||
|
||||
declare function compressible(type: string): boolean | undefined;
|
||||
22
types/compressible/tsconfig.json
Normal file
22
types/compressible/tsconfig.json
Normal file
@@ -0,0 +1,22 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"compressible-tests.ts"
|
||||
]
|
||||
}
|
||||
1
types/compressible/tslint.json
Normal file
1
types/compressible/tslint.json
Normal file
@@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Reference in New Issue
Block a user