From 6cbb2e51796cccab8bf6e9d88775971921fdd77c Mon Sep 17 00:00:00 2001 From: Piotr Roszatycki Date: Thu, 9 Nov 2017 17:09:46 +0100 Subject: [PATCH 1/2] New typings for module wtfnode --- types/wtfnode/index.d.ts | 7 +++++++ types/wtfnode/tsconfig.json | 23 +++++++++++++++++++++++ types/wtfnode/tslint.json | 1 + types/wtfnode/wtfnode-tests.ts | 4 ++++ 4 files changed, 35 insertions(+) create mode 100644 types/wtfnode/index.d.ts create mode 100644 types/wtfnode/tsconfig.json create mode 100644 types/wtfnode/tslint.json create mode 100644 types/wtfnode/wtfnode-tests.ts diff --git a/types/wtfnode/index.d.ts b/types/wtfnode/index.d.ts new file mode 100644 index 0000000000..0f6c53c32f --- /dev/null +++ b/types/wtfnode/index.d.ts @@ -0,0 +1,7 @@ +// Type definitions for wtfnode 0.5 +// Project: https://github.com/myndzi/wtfnode +// Definitions by: Piotr Roszatycki +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped + +export function dump(): void; +export function init(): void; diff --git a/types/wtfnode/tsconfig.json b/types/wtfnode/tsconfig.json new file mode 100644 index 0000000000..5e3a159ea2 --- /dev/null +++ b/types/wtfnode/tsconfig.json @@ -0,0 +1,23 @@ +{ + "compilerOptions": { + "module": "commonjs", + "lib": [ + "es6" + ], + "noImplicitAny": true, + "noImplicitThis": true, + "strictNullChecks": false, + "strictFunctionTypes": true, + "baseUrl": "../", + "typeRoots": [ + "../" + ], + "types": [], + "noEmit": true, + "forceConsistentCasingInFileNames": true + }, + "files": [ + "index.d.ts", + "wtfnode-tests.ts" + ] +} diff --git a/types/wtfnode/tslint.json b/types/wtfnode/tslint.json new file mode 100644 index 0000000000..3db14f85ea --- /dev/null +++ b/types/wtfnode/tslint.json @@ -0,0 +1 @@ +{ "extends": "dtslint/dt.json" } diff --git a/types/wtfnode/wtfnode-tests.ts b/types/wtfnode/wtfnode-tests.ts new file mode 100644 index 0000000000..a87800aee5 --- /dev/null +++ b/types/wtfnode/wtfnode-tests.ts @@ -0,0 +1,4 @@ +import * as wtf from 'wtfnode'; + +wtf.init(); +wtf.dump(); From 206bba6bb6dd0fe0bba1b279f00ebb6c89db7393 Mon Sep 17 00:00:00 2001 From: Piotr Roszatycki Date: Fri, 10 Nov 2017 11:35:21 +0100 Subject: [PATCH 2/2] Fixed errors after dts-gen --- types/wtfnode/index.d.ts | 2 +- types/wtfnode/tsconfig.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/types/wtfnode/index.d.ts b/types/wtfnode/index.d.ts index 0f6c53c32f..a33af419c3 100644 --- a/types/wtfnode/index.d.ts +++ b/types/wtfnode/index.d.ts @@ -1,6 +1,6 @@ // Type definitions for wtfnode 0.5 // Project: https://github.com/myndzi/wtfnode -// Definitions by: Piotr Roszatycki +// Definitions by: Piotr Roszatycki // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped export function dump(): void; diff --git a/types/wtfnode/tsconfig.json b/types/wtfnode/tsconfig.json index 5e3a159ea2..429ee54cb7 100644 --- a/types/wtfnode/tsconfig.json +++ b/types/wtfnode/tsconfig.json @@ -6,7 +6,7 @@ ], "noImplicitAny": true, "noImplicitThis": true, - "strictNullChecks": false, + "strictNullChecks": true, "strictFunctionTypes": true, "baseUrl": "../", "typeRoots": [