4 ms·
> has growing pain with typescript and esm support. I'm curious - what do you mean by this? Been using Jest in multiple codebases with typescript and ES Module
by madeofpalk 5y ago
> has growing pain with typescript and esm support.
I'm curious - what do you mean by this? Been using Jest in multiple codebases with typescript and ES Modules and never ran into an issue.
- brundolf 5y agoMy experience has been that basically every time you need to change your Babel/typescript/webpack configuration you have to do it a second time, with a different set of quirks and constraints, for Jest. It's not a blocker but it's a persistent pain
- rattlesnakedave 5y agoI remember having trouble with this recently. No specific examples to cite because I gave up and nuked the project, but support for ESM is experimental in Jest. I literally just couldn't get it to work with ES6. I remember thinking I would have to compile to CJS so jest would work. edit: just found this, which seems to confirm my anecdotal xp of esm in jest being weird https://github.com/facebook/jest/pull/11529#issuecomment-1027091448 https://github.com/facebook/jest/pull/11529#issuecomment-102...