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
error TS2351: This expression is not constructable.
Type 'typeof import("C:/Users/[...]/node_modules/@pothos/core/dts/index")' has no construct signatures.
I think this is a bug in ts-jest. If you follow the esm documentation it says:
Ensure that tsconfig has module with value for ESM, e.g. ES2015 or ES2020 etc...
If change your tsconfig to use those settings:
"module": "ES2022",
"moduleResolution": "Node",
Everything works fine. The error you are seeing comes from typescript using settings different than those in the tsconfig in the repo (running the build command/tsc works fine).
I'd recommend opening an issue with ts-jest, since this seems related to them changing or not respecting some options in the repos tsconfig. I personally don't use ts-jest, so not sure about next steps for debugging this further
Code:
Error when running test:
Package versions:
Repository with error reproduction
Related: #597
The text was updated successfully, but these errors were encountered: