You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am getting the following error: Must use import to load ES Module: [...]/node_modules/@polkadot/x-bigint/shim.js. Any insights on how to solve this would be appreciated. I tried configuring my jest config file and tsconfig.json in multiple ways, but nothing seems to work.
The text was updated successfully, but these errors were encountered:
akileshtangella
changed the title
polkadjot-js 7.11.1 not working with jest testing framework
@polkadjot/api 7.11.1 not working with jest testing framework
Mar 8, 2022
akileshtangella
changed the title
@polkadjot/api 7.11.1 not working with jest testing framework
@polkadot/api 7.11.1 not working with jest testing framework
Mar 8, 2022
The bottom-line is that Jest ESM support seems to be lagging behind and it pulls in ESM despite the export maps. Most of the above issues have workarounds/configurations.
EDIT: It seems the upstream Jest issue for export map support is closed (just in time for the Node 12 deprecation where it was first added) and they seem to support it in Jest 28 (only alpha for now) from my reading of jestjs/jest#9771
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue if you think you have a related problem or query.
I am getting the following error:
Must use import to load ES Module: [...]/node_modules/@polkadot/x-bigint/shim.js
. Any insights on how to solve this would be appreciated. I tried configuring myjest
config file andtsconfig.json
in multiple ways, but nothing seems to work.The text was updated successfully, but these errors were encountered: