Skip to content
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

Supporting .js imports for TypeScript #508

Closed
guybedford opened this issue Feb 19, 2020 · 1 comment · Fixed by #510
Closed

Supporting .js imports for TypeScript #508

guybedford opened this issue Feb 19, 2020 · 1 comment · Fixed by #510

Comments

@guybedford
Copy link
Contributor

I just created an issue for this on the ts-loader project at TypeStrong/ts-loader#1056. I think this would be a useful feature to allow better module compat.

@guybedford
Copy link
Contributor Author

guybedford commented Feb 20, 2020

Closing as a non-bug since it appears this is working correctly after all!.

Edit: wrong repo, meant to close TypeStrong/ts-loader#1056.

@guybedford guybedford reopened this Feb 20, 2020
styfle pushed a commit that referenced this issue Feb 21, 2020
This resolves #508 in allowing the pattern for TypeScript code using `.js` extensions to reference other TypeScript files.

This is currently recommended by the TypeScript team (microsoft/TypeScript#16577 (comment)) as an approach for writing TypeScript that will include the file extensions in the output files when using `tsc` manually, resulting in Node.js and browser compatibility for the output.

With this PR, ncc doesn't have to break enabling this workflow for users, while remaining backwards compatible with the previous behaviour so it would be fine to release this as a minor.
musaevonline added a commit to musaevonline/react-animation-ncc that referenced this issue Dec 4, 2021
This resolves vercel/ncc#508 in allowing the pattern for TypeScript code using `.js` extensions to reference other TypeScript files.

This is currently recommended by the TypeScript team (microsoft/TypeScript#16577 (comment)) as an approach for writing TypeScript that will include the file extensions in the output files when using `tsc` manually, resulting in Node.js and browser compatibility for the output.

With this PR, ncc doesn't have to break enabling this workflow for users, while remaining backwards compatible with the previous behaviour so it would be fine to release this as a minor.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant