From ae4a5031793d0e60091439503ccd1ccd77deaf34 Mon Sep 17 00:00:00 2001 From: Artemii Kravtsov Date: Wed, 3 Mar 2021 16:51:31 +0200 Subject: [PATCH 1/3] TypeScript fix by adding global declaration file --- package.json | 2 +- types/index.d.ts | 3 +++ types/{parameters.ts => parameters.d.ts} | 0 types/{user.ts => user.d.ts} | 0 4 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 types/index.d.ts rename types/{parameters.ts => parameters.d.ts} (100%) rename types/{user.ts => user.d.ts} (100%) diff --git a/package.json b/package.json index 0ff705a..ea028a1 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "test": "tests" }, "main": "src/client.ts", - "types": "src/client.ts", + "types": "types/index.d.ts", "scripts": { "prepare": "npm run build", "build": "tsc", diff --git a/types/index.d.ts b/types/index.d.ts new file mode 100644 index 0000000..807d0f7 --- /dev/null +++ b/types/index.d.ts @@ -0,0 +1,3 @@ +import ImmudbClient from '../src/client' + +export default ImmudbClient \ No newline at end of file diff --git a/types/parameters.ts b/types/parameters.d.ts similarity index 100% rename from types/parameters.ts rename to types/parameters.d.ts diff --git a/types/user.ts b/types/user.d.ts similarity index 100% rename from types/user.ts rename to types/user.d.ts From dddefc4d8480ded2b35f16783a011f21ba69eaed Mon Sep 17 00:00:00 2001 From: Artemii Kravtsov Date: Wed, 3 Mar 2021 16:52:02 +0200 Subject: [PATCH 2/3] bump version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ea028a1..1cbb868 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "immudb-node", - "version": "1.0.10-rc.1", + "version": "1.0.10-rc.2", "description": "Node ts client for immudb", "directories": { "src": "src", From dee8446facd5d40008d42c1bb28c254cbce137d5 Mon Sep 17 00:00:00 2001 From: Artemii Kravtsov Date: Wed, 3 Mar 2021 17:15:09 +0200 Subject: [PATCH 3/3] TypeScript fix by changing package.json; bump version --- package.json | 6 +++--- tsconfig.json | 25 +++++++++++++------------ 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/package.json b/package.json index 1cbb868..61cc123 100644 --- a/package.json +++ b/package.json @@ -1,13 +1,13 @@ { "name": "immudb-node", - "version": "1.0.10-rc.2", + "version": "1.0.10-rc.3", "description": "Node ts client for immudb", "directories": { "src": "src", "test": "tests" }, - "main": "src/client.ts", - "types": "types/index.d.ts", + "main": "dist/src/client.js", + "types": "dist/src/client.d.ts", "scripts": { "prepare": "npm run build", "build": "tsc", diff --git a/tsconfig.json b/tsconfig.json index 8be411a..68ca22d 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,17 +1,18 @@ { "compilerOptions": { - "target": "ES2017", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', or 'ESNEXT'. */ - "module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */ - "strict": true, /* Enable all strict type-checking options. */ - "esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */ - "skipLibCheck": true, /* Skip type checking of declaration files. */ - "forceConsistentCasingInFileNames": true, /* Disallow inconsistently-cased references to the same file. */ - "sourceMap": true, - "declaration": true, - "outDir": "dist", - // "allowJs": true, - "baseUrl": "src", - // "moduleResolution": "classic" + "target": "ES2017", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', or 'ESNEXT'. */ + "module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */ + "strict": true, /* Enable all strict type-checking options. */ + "esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */ + "skipLibCheck": true, /* Skip type checking of declaration files. */ + "forceConsistentCasingInFileNames": true, /* Disallow inconsistently-cased references to the same file. */ + "sourceMap": true, + "declaration": true, + "outDir": "./dist", + "rootDir": "./src", + // "allowJs": true, + "baseUrl": "src", + // "moduleResolution": "classic" }, "files": [ "./node_modules/@types/mocha/index.d.ts",