Skip to content

Commit f744447

Browse files
Rocco Bruynkum-deepak
authored andcommitted
Define exports for ESM/CommonJS in package.json (#665)
1 parent 0efa0db commit f744447

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

package.json

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,17 @@
5353
},
5454
"type": "module",
5555
"exports": {
56-
"import": "./esm6/index.js",
57-
"require": "./bundles/stomp.umd.js"
56+
".": {
57+
"browser": "./bundles/stomp.umd.js",
58+
"require": {
59+
"types": "./index.d.ts",
60+
"default": "./bundles/stomp.umd.js"
61+
},
62+
"import": {
63+
"types": "./index.d.ts",
64+
"default": "./esm6/index.js"
65+
}
66+
}
5867
},
5968
"main": "./bundles/stomp.umd.js",
6069
"browser": "./bundles/stomp.umd.js",

0 commit comments

Comments
 (0)