Skip to content

Commit 1e9dba9

Browse files
committed
feat: add cjs support for npm package
1 parent 489e8ea commit 1e9dba9

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

package.json

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,20 @@
55
"author": "maxgfr",
66
"license": "MIT",
77
"description": "A minimalist typescript swc starter",
8+
"main": "./dist/cjs/index.js",
9+
"module": "dist/esm/index.js",
810
"exports": {
911
".": {
10-
"import": "./dist/esm/index.js",
12+
"require": "./dist/cjs/index.js",
13+
"import": "./dist/esm/index.js"
14+
},
15+
"./dist/cjs/index.js": {
1116
"require": "./dist/cjs/index.js"
17+
},
18+
"./dist/esm/index.js": {
19+
"import": "./dist/esm/index.js"
1220
}
1321
},
14-
"main": "./dist/cjs/index.js",
1522
"repository": {
1623
"type": "git",
1724
"url": "https://github.com/maxgfr/typescript-swc-starter.git"

0 commit comments

Comments
 (0)