Replies: 2 comments 8 replies
-
@MoutPessemier avoids babel when testing with jest in https://github.com/MoutPessemier/enhancedMathJS "ts-node": "^9.0.0" passes the jest.config.ts without error:
but switching to
and passing a node loader option to the
then solution for packages not exporting in es6:
|
Beta Was this translation helpful? Give feedback.
-
Upgrading to As explained by @cspotcode in that issue, this is not a regression and it is a change called out in the release changelog:
The fix to unblock an upgrade is a work-in-progress at the moment; I like the sound of migrating to CommonJS (also called Removing Note: one peculiarity -- potentially relevant to TS compilation -- of this codebase is that it includes a module self-dependency. It's a series of what are essentially database migrations, and the idea is to be able to deploy a JS application that at any time includes a full series of those migrations (A->B->C) using NPM's dependency management and resolution instead of having to rely on filename ordering and/or migration IDs to enforce a migration graph). I'd appreciate any help and references regarding completing the migration to CommonJS -- or, equally, suggestions about why other approaches might be better. |
Beta Was this translation helpful? Give feedback.
-
This discussion thread exists to ask questions about the new version. If anything in the release notes is confusing, or if you encounter problems with the upgrade, you can post your questions below.
Release notes
Many of the breaking changes in v10.0.0 will only affect very rare cases. For the vast majority of users, these changes will have no effect. Some improve
ts-node
's automatic behavior in special cases, such as writing portable shell scripts that live on your$PATH
or are executed withnpx
without any compilation or boilerplate. Others more closely align our behavior with vanillanode
. They are intended to improve quality-of-life for all users.As needed, we can explain these changes in greater detail in threads below.
Beta Was this translation helpful? Give feedback.
All reactions