-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Open
Labels
Domain: Refactoringse.g. extract to constant or function, rename symbole.g. extract to constant or function, rename symbolExperience EnhancementNoncontroversial enhancementsNoncontroversial enhancementsSuggestionAn idea for TypeScriptAn idea for TypeScript
Milestone
Description
π Search Terms
AllowUnresolveNames, "preserve type nodes"
π Version & Regression Information
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about AllowUnresolvedNames and preserve types
β― Playground Link
π» Code
interface A {
foo: import("./doesntexist.js").Foo;
get bar(): import("./doesntexist.js").Foo;
}
class B implements A {
// Trigger completion: "implement interface A" display this completion:
// Actual:
// foo: any;
// get bar(): any {
// throw new Error("Method not implemented.");
// }
// Expected:
// foo: import("./doesntexist.js").Foo;
// get bar(): import("./doesntexist.js").Foo {
// throw new Error("Method not implemented.");
// }
}
π Actual behavior
Triggering completion uses any
instead of the unresolved type.
π Expected behavior
Completion should be the unresolved type instead of any
Additional information about the issue
Found in PR #59440
Metadata
Metadata
Assignees
Labels
Domain: Refactoringse.g. extract to constant or function, rename symbole.g. extract to constant or function, rename symbolExperience EnhancementNoncontroversial enhancementsNoncontroversial enhancementsSuggestionAn idea for TypeScriptAn idea for TypeScript