Skip to content

Commit 609c0a2

Browse files
committed
fix(devtools): Update ESM export extension
1 parent 45a810c commit 609c0a2

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

packages/query-devtools/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@
1212
},
1313
"types": "build/types/index.d.ts",
1414
"main": "build/umd/index.js",
15-
"module": "build/esm/index.js",
15+
"module": "build/esm/index.mjs",
1616
"exports": {
1717
".": {
1818
"types": "./build/types/index.d.ts",
19-
"import": "./build/esm/index.js",
19+
"import": "./build/esm/index.mjs",
2020
"require": "./build/umd/index.js",
2121
"default": "./build/umd/index.js"
2222
},

rollup.config.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -499,6 +499,10 @@ function createTanstackQueryDevtoolsConfig() {
499499
outputs.forEach((output) => {
500500
const format = output.format
501501
output.dir = `${packageDir}/build/${format}`
502+
if (output.format === 'esm') {
503+
output.dir = undefined
504+
output.file = `${packageDir}/build/${format}/index.mjs`
505+
}
502506
})
503507

504508
solidRollupOptions.external = []

0 commit comments

Comments
 (0)