Skip to content

Commit 43acd1a

Browse files
committed
build: use tsconfig.prod.json
1 parent 29d4891 commit 43acd1a

File tree

4 files changed

+23
-18
lines changed

4 files changed

+23
-18
lines changed

.eslintrc.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
11
module.exports = {
2-
extends: ['./node_modules/ts-standardx/.eslintrc.js'],
3-
parserOptions: {
4-
project: ['./tsconfig.eslint.json']
5-
}
2+
extends: ['./node_modules/ts-standardx/.eslintrc.js']
63
}

package.json

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@
44
"private": true,
55
"main": "lib/index.js",
66
"scripts": {
7-
"build": "rm -rf lib && tsc",
8-
"test": "ts-standardx && jest",
7+
"build": "rm -rf lib && tsc -p tsconfig.prod.json",
8+
"test": "npm run build && ts-standardx && jest",
99
"package": "ncc build --license licenses.txt",
10-
"all": "npm run build && npm test && npm run package",
11-
"format": "ts-standardx --fix"
10+
"all": "npm test && npm run package"
1211
},
1312
"repository": {
1413
"type": "git",

tsconfig.json

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,17 @@
11
{
22
"compilerOptions": {
3-
"target": "ES2015",
4-
"module": "commonjs",
5-
"outDir": "./lib",
6-
"rootDir": "./src",
73
"strict": true,
4+
5+
"module": "commonjs",
86
"moduleResolution": "node",
7+
8+
"noEmit": true,
9+
910
"esModuleInterop": true,
10-
"skipLibCheck": true,
11-
"forceConsistentCasingInFileNames": true
12-
},
13-
"include": [
14-
"./src/**/*.ts"
15-
]
11+
"forceConsistentCasingInFileNames": true,
12+
13+
"target": "es2019",
14+
15+
"skipLibCheck": true
16+
}
1617
}

tsconfig.prod.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"extends": "./tsconfig.json",
3+
"compilerOptions": {
4+
"noEmit": false,
5+
"outDir": "./lib"
6+
},
7+
"exclude": ["__tests__/**/*"]
8+
}

0 commit comments

Comments
 (0)