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

Support resolving .ts files from .js extensions #51

Open
benjamind opened this issue Dec 15, 2023 · 0 comments
Open

Support resolving .ts files from .js extensions #51

benjamind opened this issue Dec 15, 2023 · 0 comments

Comments

@benjamind
Copy link

Modern NodeNext resolve strategies, and Typescript team itself historically, require that imports end with .js extension.

The plugin right now simply appends extensions to try, rather than changing extensions. So if you have a TS project and have an import of the form:

import { Foo } from './foo.js';

The file to resolve may actually be called foo.ts on disk, and hence the current plugin resolve strategy won't find it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant