Skip to content

Commit 0bf4860

Browse files
authored
fix: drop browser export condition pointing at the ESM build (#87)
Jest 28+ resolves the browser condition under jest-environment-jsdom and then loads dist/esm/index.mjs as CommonJS, failing with "Cannot use import statement outside a module". Bundlers already pick the same file through the import condition, so the browser entries only affected Jest. Fixes #70
1 parent 0009053 commit 0bf4860

1 file changed

Lines changed: 0 additions & 2 deletions

File tree

‎package.json‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,11 @@
88
"exports": {
99
".": {
1010
"types": "./types/index.d.ts",
11-
"browser": "./dist/esm/index.mjs",
1211
"import": "./dist/esm/index.mjs",
1312
"require": "./dist/cjs/index.js"
1413
},
1514
"./pure": {
1615
"types": "./pure.d.ts",
17-
"browser": "./dist/esm/pure.mjs",
1816
"import": "./dist/esm/pure.mjs",
1917
"require": "./dist/cjs/pure.js"
2018
}

0 commit comments

Comments
 (0)