-
Notifications
You must be signed in to change notification settings - Fork 369
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
import 6.0.1 TS project issue #409
Comments
I've been working on fixes for this. Could you try this beta version to see if it works for you?
(See #405 for more details.) |
hi that was fast Sadly it didnt work for my tsconfig. |
What happens if you use |
hmm doesnt work too |
It's a little hard for me to figure out what's going wrong. Could you create a sample project that reproduces the issue? It probably just has a |
ok worked with module:commonjs |
Glad you solved it.
I'll see if I can improve this for other people in the future.
|
Hi
imported "helmet": "^6.0.1" into express ts node project and faced the following error; Not sure why it would refer to the CJS module when I am using
import helmet from "helmet";
TS1479: The current file is a CommonJS module whose imports will produce 'require' calls; however, the referenced file is an ECMAScript module and cannot be imported with 'require'. Consider writing a dynamic 'import("helmet")' call instead. To convert this file to an ECMAScript module, change its file extension to '.mts', or add the field
"type": "module"to ...
uploaded tsconfig
tsconfig copy.json.txt
thanks for taking a look
The text was updated successfully, but these errors were encountered: