Skip to content

Commit 464642e

Browse files
committed
feat: emit code in ES Module mode
1 parent 27cadf9 commit 464642e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
"version": "6.1.0",
44
"description": "Collection of React Hooks",
55
"main": "lib/index.js",
6+
"module": "lib/es/index.js",
67
"files": [
78
"lib/"
89
],
@@ -11,7 +12,9 @@
1112
"scripts": {
1213
"start": "yarn storybook",
1314
"test": "echo hmm...",
14-
"build": "tsc",
15+
"build:cjs": "tsc",
16+
"build:es": "tsc -m esNext --outDir lib/es",
17+
"build": "yarn build:cjs && yarn build:es",
1518
"clean": "rimraf lib storybook-static",
1619
"storybook": "start-storybook -p 6008",
1720
"storybook:build": "build-storybook",

0 commit comments

Comments
 (0)