-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Please make default import check __esModule flag at runtime! #16090
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
Comments
Yes it should! See #16093 🎉 🎉 |
It'll be great to see this change. I recently switched from Babel to TS as my transpiler for miniSphere as it's so much faster, but since I support both CommonJS and ES modules, my standard library is entirely CJS. The change broke a few modules as a result. |
Updated title to make it a request rather than a question. |
tracked by #16093 |
Automatically closing this issue for housekeeping purposes. The issue labels indicate that it is unactionable at the moment or has already been addressed. |
TypeScript Version: 2.3.3
Input Code
My example is from a
.js
file with --allowJs. I've tried with and without --allowSyntheticDefaultImports, doesn't seem to make a difference.Expected behavior:
I think this should generate something like:
Actual behavior:
babel's output
workaround
Obviously I can work around this with a change to the input code:
The text was updated successfully, but these errors were encountered: