diff --git a/.vscode/tasks.json b/.vscode/tasks.json index e07321f..fa7538b 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -27,11 +27,23 @@ { "label": "npm publish", "type": "shell", - "command": "yarn build && npm publish -d ../build", + "command": "npm publish -d ../build", + "dependsOn": [ + "npm build", + ], "options": { "cwd": "./web/src" }, "problemMatcher": [] - } + }, + { + "label": "npm build", + "type": "shell", + "command": "yarn build", + "options": { + "cwd": "./web/src" + }, + "problemMatcher": [] + }, ] } diff --git a/web/src/lib/index.ts b/web/src/lib/index.ts index 6c6aabb..977c9d2 100644 --- a/web/src/lib/index.ts +++ b/web/src/lib/index.ts @@ -1,4 +1,4 @@ -import * as _data from "./dw_data.json" +import _data from "./dw_data.json" export * from "./types" import { DungeonWorldRepository } from "./types" diff --git a/web/src/lib/types.d.ts b/web/src/lib/types.ts similarity index 100% rename from web/src/lib/types.d.ts rename to web/src/lib/types.ts diff --git a/web/src/package.json b/web/src/package.json index b154ae4..587c65b 100755 --- a/web/src/package.json +++ b/web/src/package.json @@ -1,6 +1,6 @@ { "name": "dw-data", - "version": "3.0.0-pre.15", + "version": "3.0.0-pre.20", "main": "index.js", "repository": "https://github.com/chenasraf/dungeon_world_data", "author": "Chen Asraf ", @@ -9,7 +9,7 @@ "scripts": { "prebuild": "cd ../.. && dart scripts/parsers/dart_to_json.dart", "build": "tsc", - "postbuild": "cp lib/types.d.ts package.json ../build/" + "postbuild": "cp package.json ../build/" }, "devDependencies": { "typescript": "^4.7.4" diff --git a/web/src/tsconfig.json b/web/src/tsconfig.json index 20b577f..e06d1f2 100644 --- a/web/src/tsconfig.json +++ b/web/src/tsconfig.json @@ -63,7 +63,7 @@ // "declarationDir": "./", /* Specify the output directory for generated declaration files. */ // "preserveValueImports": true, /* Preserve unused imported values in the JavaScript output that would otherwise be removed. */ /* Interop Constraints */ - "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */ + // "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */ "allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */ "esModuleInterop": true, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */ // "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */