Skip to content

Commit 4e2ffe8

Browse files
committed
fix(config): enhance package.json and tsconfig.json
1 parent f381b54 commit 4e2ffe8

File tree

3 files changed

+9
-7
lines changed

3 files changed

+9
-7
lines changed

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
"name": "commitlint-plugin-prevenger",
33
"version": "1.0.2",
44
"main": "dist/index.js",
5+
"type": "module",
56
"scripts": {
67
"test": "jest --coverage",
78
"build": "tsc"

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { default as scopePattern } from "./rules/scope-pattern";
1+
import { default as scopePattern } from "./rules/scope-pattern/index.js";
22

33
export const rules = {
44
'scope-pattern': scopePattern

tsconfig.json

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
{
22
"compilerOptions": {
3-
"target": "ES2019",
4-
"module": "CommonJS",
5-
"outDir": "dist",
6-
"declaration": true,
3+
"target": "ES2020",
4+
"module": "node16",
5+
"declaration": true, // <-- THIS enables .d.ts files
6+
"declarationMap": false,
7+
"emitDeclarationOnly": false,
8+
"outDir": "dist", // <-- All compiled files go here
79
"strict": true,
810
"esModuleInterop": true,
911
"skipLibCheck": true
10-
},
11-
"include": ["src"]
12+
}
1213
}

0 commit comments

Comments
 (0)