Skip to content

Commit 9ff8442

Browse files
committed
Add a dedicated tsconfig for npm packaging using ES5
1 parent 804f3b4 commit 9ff8442

2 files changed

Lines changed: 21 additions & 1 deletion

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
},
7575
"scripts": {
7676
"vscode:prepublish": "tsc -p ./",
77-
"dist": "rm -r ./out; tsc -p ./ --lib 'ES5' --target 'ES5' --sourceMap false --downlevelIteration true && npx gulp merge-packagejson-for-npm-dist && cp README.md out && cp LICENSE out && cd out && npm pack",
77+
"dist": "rm -r ./out; tsc -p ./tsconfig.dist.json && npx gulp merge-packagejson-for-npm-dist && cp README.md out && cp LICENSE out && cd out && npm pack",
7878
"compile": "tsc -p ./",
7979
"pretest": "npm run compile",
8080
"test": "npx gulp copy-systemTest-resources && node ./out/test/index.js",

tsconfig.dist.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"compilerOptions": {
3+
"module": "commonjs",
4+
"target": "ES5",
5+
"outDir": "out",
6+
"lib": [ "ES5" ],
7+
"sourceMap": false,
8+
"rootDir": ".",
9+
"downlevelIteration": true
10+
},
11+
"include": [
12+
"src/**/*",
13+
"cli/**/*"
14+
],
15+
"exclude": [
16+
"node_modules",
17+
".vscode-test",
18+
"test/**/*"
19+
]
20+
}

0 commit comments

Comments
 (0)