mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-06-04 19:42:46 +08:00
Add types for pupa@1.0.0
This commit is contained in:
8
types/pupa/index.d.ts
vendored
Normal file
8
types/pupa/index.d.ts
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
// Type definitions for pupa 1.0
|
||||
// Project: https://github.com/sindresorhus/pupa
|
||||
// Definitions by: nju33 <https://github.com/nju33>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
declare function pupa(tpl: string, data: any[] | {[key: string]: any}): string | never;
|
||||
|
||||
export = pupa;
|
||||
4
types/pupa/pupa-tests.ts
Normal file
4
types/pupa/pupa-tests.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import pupa = require('pupa');
|
||||
|
||||
pupa('{str}ing', {str: 'str'});
|
||||
pupa('{0}{1}', ['str', 'ing']);
|
||||
23
types/pupa/tsconfig.json
Normal file
23
types/pupa/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",
|
||||
"pupa-tests.ts"
|
||||
]
|
||||
}
|
||||
1
types/pupa/tslint.json
Normal file
1
types/pupa/tslint.json
Normal file
@@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Reference in New Issue
Block a user