That it why i use native functions.
No typescript syntax, no jest.
For testing i use just the native test runner, and that works great with ESM.
Jest has indeed still not good ESM support, you can do some Babel trics, but makes the process too complex.
Best is to find an alternative, like the native test runner.
Also typescript try some things that are not stable at ecma.
It was too soon with the import/export, and dont use the native way.
Also commonjs is still the default at typescript after compiling, but Node is moving to ESM as a default.
I hope typescript will use more native functions that are already available and dont use their own way.For me typescript syntax and jest is a no go.
Typescript is useful to check types, but i write just JavaScript with JSDoc, and check it with eslint in typescript modus.
No comments yet.