Skip to content

Commit c76a831

Browse files
authored
Update tsconfig to use CommonJS module (#34)
1 parent 972c453 commit c76a831

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

package.json

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
{
22
"name": "joi-password-complexity",
3-
"version": "5.0.1",
3+
"version": "5.0.2",
44
"description": "Joi validation for password complexity requirements.",
55
"main": "lib/index.js",
6+
"types": "lib/index.d.ts",
67
"scripts": {
78
"test": "jest",
89
"lint": "eslint src --ext .js,.ts",
910
"lint-fix": "yarn lint --fix",
10-
"build": "tsc -p tsconfig.json"
11+
"build": "tsc -p tsconfig.json",
12+
"prepublishOnly": "yarn build"
1113
},
1214
"repository": {
1315
"type": "git",
@@ -37,6 +39,9 @@
3739
"joi": "^17.3.0",
3840
"typescript": "^4.0.5"
3941
},
42+
"files": [
43+
"lib"
44+
],
4045
"keywords": [
4146
"Joi",
4247
"validation",

tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"allowSyntheticDefaultImports": true,
1010
"strict": true,
1111
"forceConsistentCasingInFileNames": true,
12-
"module": "esnext",
12+
"module": "CommonJS",
1313
"moduleResolution": "node",
1414
"resolveJsonModule": true,
1515
"isolatedModules": true,

0 commit comments

Comments
 (0)