-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Closed
Labels
Domain: Error MessagesThe issue relates to error messagingThe issue relates to error messagingEffort: ModerateRequires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Fix AvailableA PR has been opened for this issueA PR has been opened for this issueHelp WantedYou can do thisYou can do thisSuggestionAn idea for TypeScriptAn idea for TypeScript
Milestone
Description
When an extensionless import fails from an ES module when moduleResolution
is effectively node12
/nodenext
, we currently issue a useless error message.
// @filename: ./foo.mts
export function foo() {
}
// @filename: ./bar.mts
import foo from "./foo";
// error: Cannot find module './foo' or its corresponding type declarations.
Instead, we should see if we managed to find any files with an extension, or at least mention that an extensionless import is likely to fail.
robpalme, nickluger and kevinalh
Metadata
Metadata
Assignees
Labels
Domain: Error MessagesThe issue relates to error messagingThe issue relates to error messagingEffort: ModerateRequires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Fix AvailableA PR has been opened for this issueA PR has been opened for this issueHelp WantedYou can do thisYou can do thisSuggestionAn idea for TypeScriptAn idea for TypeScript