diff --git a/esbuild.js b/esbuild.js index 2af7eda..967b2e2 100644 --- a/esbuild.js +++ b/esbuild.js @@ -1,21 +1,20 @@ // @ts-check const esbuild = require('esbuild'); const path = require('node:path'); -const os = require('node:os'); const { sassPlugin } = require('esbuild-sass-plugin'); /** @typedef {import('esbuild').BuildOptions} BuildOptions */ const args = process.argv.slice(2); const CLIWatch = args.includes('--watch'); -const CLIDevelopment = CLIWatch || args.includes('--development'); +const NoMinify = args.includes('--no-minify'); /** @type {BuildOptions} */ const commonConfig = { bundle: true, target: ['es2020'], - minify: !CLIDevelopment, - sourcemap: CLIDevelopment, + minify: !NoMinify, + sourcemap: true, }; const srcDir = path.join(__dirname, 'src'); diff --git a/package.json b/package.json index 50ebf43..c8304df 100644 --- a/package.json +++ b/package.json @@ -15,6 +15,7 @@ }, "homepage": "https://github.com/eclipse-cdt-cloud/cdt-gdb-vscode#readme", "main": "./dist/extension", + "types": "./dist/extension.d.ts", "engines": { "vscode": "^1.78.0" }, @@ -770,6 +771,12 @@ "CONTRIBUTING.md", "dist/**/*.js", "dist/**/*.js.map", - "dist/**/*.d.ts" + "dist/**/*.css", + "dist/**/*.css.map", + "dist/**/*.d.ts", + "dist/**/*.d.ts.map", + "src/**/*.ts", + "src/**/*.tsx", + "src/**/*.scss" ] } diff --git a/tsconfig.json b/tsconfig.json index 3dcb36e..8d1b690 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -8,6 +8,8 @@ "lib": ["es2015", "dom"], "jsx": "react", "strict": true, + "declaration": true, + "declarationMap": true, "noImplicitAny": true, "noImplicitReturns": true, "noUnusedLocals": true, @@ -17,5 +19,5 @@ "preserveWatchOutput": true }, "references": [{ "path": "src/memory/client/tsconfig.json" }], - "exclude": ["**/client/*"] + "exclude": ["**/client/*", "**/dist/*"] }