Open wub opened 1 year ago
I was using the version 2.0.4
and after upgrading to 2.1.0
facing the same problem.
I have the same issue. Since it was not solved since April i decided fork library. Package ESM entrypoint needs to be upgraded.
I changed in package.json from:
"exports": {
".": {
"import": "./dist/chakra-ui-steps.mjs",
"require": "./dist/chakra-ui-steps.umd.cjs"
}
}
to:
"exports": {
".": {
"import": {
"default": "./dist/chakra-ui-steps.mjs",
"types": "./dist/index.d.ts"
},
"require": "./dist/chakra-ui-steps.umd.js"
}
}
Currently works as expected :)
Explanation here: https://stackoverflow.com/questions/72457791/typescript-packages-that-ship-with-mjs-and-d-ts-but-without-d-mts-how-to-i
After upgrading to 2.1.0, I have the same problem with the Jest test.
https://github.com/jeanverster/chakra-ui-steps/issues/134#issuecomment-1725255696 this worked for me too.
FAIL src/component/index.spec.tsx ● Test suite failed to run
Cannot find module 'chakra-ui-steps' from 'src/theme/index.ts'
Require stack:
src/theme/index.ts
test/index.tsx
src/component/index.spec.tsx
After updating from 2.0.4 to 2.1.0, I now get this error (using this with Remix - so the code is running on both server and client).
I imagine it might have something to do with this change?
2.0.4:
2.1.0: