From f7bc7b7f913df127a5ae29b3d37b5d50671bdb21 Mon Sep 17 00:00:00 2001 From: Dimitri Benin Date: Tue, 25 Dec 2018 03:18:36 +0100 Subject: [PATCH] [path-regex] Add types --- types/path-regex/index.d.ts | 8 ++++++++ types/path-regex/path-regex-tests.ts | 3 +++ types/path-regex/tsconfig.json | 23 +++++++++++++++++++++++ types/path-regex/tslint.json | 1 + 4 files changed, 35 insertions(+) create mode 100644 types/path-regex/index.d.ts create mode 100644 types/path-regex/path-regex-tests.ts create mode 100644 types/path-regex/tsconfig.json create mode 100644 types/path-regex/tslint.json diff --git a/types/path-regex/index.d.ts b/types/path-regex/index.d.ts new file mode 100644 index 0000000000..be1ddb65a1 --- /dev/null +++ b/types/path-regex/index.d.ts @@ -0,0 +1,8 @@ +// Type definitions for path-regex 1.0 +// Project: https://github.com/regexps/path-regex +// Definitions by: BendingBender +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped + +export = pathRegex; + +declare function pathRegex(): RegExp; diff --git a/types/path-regex/path-regex-tests.ts b/types/path-regex/path-regex-tests.ts new file mode 100644 index 0000000000..f778b83267 --- /dev/null +++ b/types/path-regex/path-regex-tests.ts @@ -0,0 +1,3 @@ +import re = require('path-regex'); + +re(); // $ExpectType RegExp diff --git a/types/path-regex/tsconfig.json b/types/path-regex/tsconfig.json new file mode 100644 index 0000000000..cc24418a54 --- /dev/null +++ b/types/path-regex/tsconfig.json @@ -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", + "path-regex-tests.ts" + ] +} diff --git a/types/path-regex/tslint.json b/types/path-regex/tslint.json new file mode 100644 index 0000000000..3db14f85ea --- /dev/null +++ b/types/path-regex/tslint.json @@ -0,0 +1 @@ +{ "extends": "dtslint/dt.json" }