From afa0c1e93a7a86baab48af8710ab265dfac87f4e Mon Sep 17 00:00:00 2001 From: Nicolas Date: Fri, 21 Dec 2018 11:49:02 -0500 Subject: [PATCH 1/6] Add decode-entities type definitions --- .../decode-entities/decode-entities-tests.ts | 4 ++++ types/decode-entities/index.d.ts | 8 +++++++ types/decode-entities/tsconfig.json | 23 +++++++++++++++++++ types/decode-entities/tslint.json | 1 + 4 files changed, 36 insertions(+) create mode 100644 types/decode-entities/decode-entities-tests.ts create mode 100644 types/decode-entities/index.d.ts create mode 100644 types/decode-entities/tsconfig.json create mode 100644 types/decode-entities/tslint.json diff --git a/types/decode-entities/decode-entities-tests.ts b/types/decode-entities/decode-entities-tests.ts new file mode 100644 index 0000000000..9fece87667 --- /dev/null +++ b/types/decode-entities/decode-entities-tests.ts @@ -0,0 +1,4 @@ +import decodeEntities = require('decode-entities'); + +// $ExpectType string +decodeEntities('!'); \ No newline at end of file diff --git a/types/decode-entities/index.d.ts b/types/decode-entities/index.d.ts new file mode 100644 index 0000000000..7773a5cd45 --- /dev/null +++ b/types/decode-entities/index.d.ts @@ -0,0 +1,8 @@ +// Type definition for decode-entities v1.0.4 +// Project: https://github.com/waspothegreat/decode-entities#readme +// Definitions by: waspothegreat +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped + +declare function decode(encodedString: string): string; + +export = decode; diff --git a/types/decode-entities/tsconfig.json b/types/decode-entities/tsconfig.json new file mode 100644 index 0000000000..3a3967c92c --- /dev/null +++ b/types/decode-entities/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", + "decode-entities-tests.ts" + ] +} \ No newline at end of file diff --git a/types/decode-entities/tslint.json b/types/decode-entities/tslint.json new file mode 100644 index 0000000000..2750cc0197 --- /dev/null +++ b/types/decode-entities/tslint.json @@ -0,0 +1 @@ +{ "extends": "dtslint/dt.json" } \ No newline at end of file From d6963182e2222398ea1e0be1b27dbf5ed1c2cff1 Mon Sep 17 00:00:00 2001 From: Nicolas Date: Fri, 21 Dec 2018 12:15:12 -0500 Subject: [PATCH 2/6] update tests --- types/decode-entities/decode-entities-tests.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/decode-entities/decode-entities-tests.ts b/types/decode-entities/decode-entities-tests.ts index 9fece87667..09ae2b5b0e 100644 --- a/types/decode-entities/decode-entities-tests.ts +++ b/types/decode-entities/decode-entities-tests.ts @@ -1,4 +1,4 @@ import decodeEntities = require('decode-entities'); // $ExpectType string -decodeEntities('!'); \ No newline at end of file +decodeEntities('© !'); \ No newline at end of file From e26a8ca8da65512e032a4d302efa62ddb92248ee Mon Sep 17 00:00:00 2001 From: Nicolas Date: Fri, 21 Dec 2018 12:51:02 -0500 Subject: [PATCH 3/6] typo --- types/decode-entities/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/decode-entities/index.d.ts b/types/decode-entities/index.d.ts index 7773a5cd45..f4379ed041 100644 --- a/types/decode-entities/index.d.ts +++ b/types/decode-entities/index.d.ts @@ -1,4 +1,4 @@ -// Type definition for decode-entities v1.0.4 +// Type definitions for decode-entities v1.0.4 // Project: https://github.com/waspothegreat/decode-entities#readme // Definitions by: waspothegreat // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped From 25eff651c588a9128b49180e492c906e5821bc97 Mon Sep 17 00:00:00 2001 From: Nicolas <36765044+waspothegreat@users.noreply.github.com> Date: Fri, 21 Dec 2018 14:37:36 -0500 Subject: [PATCH 4/6] Update decode-entities-tests.ts --- types/decode-entities/decode-entities-tests.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/decode-entities/decode-entities-tests.ts b/types/decode-entities/decode-entities-tests.ts index 09ae2b5b0e..12df82aff7 100644 --- a/types/decode-entities/decode-entities-tests.ts +++ b/types/decode-entities/decode-entities-tests.ts @@ -1,4 +1,4 @@ import decodeEntities = require('decode-entities'); // $ExpectType string -decodeEntities('© !'); \ No newline at end of file +decodeEntities('© !'); From afae94c4211898a129ae77ff06408ca1bcee9a84 Mon Sep 17 00:00:00 2001 From: Nicolas <36765044+waspothegreat@users.noreply.github.com> Date: Fri, 21 Dec 2018 14:43:20 -0500 Subject: [PATCH 5/6] Update index.d.ts --- types/decode-entities/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/decode-entities/index.d.ts b/types/decode-entities/index.d.ts index f4379ed041..8fc2cc23a5 100644 --- a/types/decode-entities/index.d.ts +++ b/types/decode-entities/index.d.ts @@ -1,4 +1,4 @@ -// Type definitions for decode-entities v1.0.4 +// Type definitions for decode-entities 1.0 // Project: https://github.com/waspothegreat/decode-entities#readme // Definitions by: waspothegreat // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped From d215b4741d86e87c4aecbd5311a352a159799fa0 Mon Sep 17 00:00:00 2001 From: Nicolas <36765044+waspothegreat@users.noreply.github.com> Date: Fri, 21 Dec 2018 15:13:21 -0500 Subject: [PATCH 6/6] Update index.d.ts --- types/decode-entities/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/decode-entities/index.d.ts b/types/decode-entities/index.d.ts index 8fc2cc23a5..965e974092 100644 --- a/types/decode-entities/index.d.ts +++ b/types/decode-entities/index.d.ts @@ -1,6 +1,6 @@ // Type definitions for decode-entities 1.0 // Project: https://github.com/waspothegreat/decode-entities#readme -// Definitions by: waspothegreat +// Definitions by: waspothegreat // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped declare function decode(encodedString: string): string;