-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Closed
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: LS: Completion ListsThe issue relates to showing completion lists in an editorThe issue relates to showing completion lists in an editorFix AvailableA PR has been opened for this issueA PR has been opened for this issue
Milestone
Description
import { ThisDoesNotExist } from "module-that-does-not-exist ;o";
let x: /**/Request completions at /**/
Expected: ThisDoesNotExist is provided as a completion item.
Actual: ThisDoesNotExist is not in the completion list.
Basically we have some filtering in our completion list logic that says that if we're pretty certain that we're in a type position, then only provide completions for types. This works great unless you end up with an alias (ThisDoesNotExist) to a module that hasn't resolved to anything.
This is kind of a pain if you're in a partial-semantic context, where only the files that are open in the editor can be analyzed. For that reason, in cases where an import hasn't resolved to anything, it makes sense to keep it in the completion list.
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: LS: Completion ListsThe issue relates to showing completion lists in an editorThe issue relates to showing completion lists in an editorFix AvailableA PR has been opened for this issueA PR has been opened for this issue