-
Notifications
You must be signed in to change notification settings - Fork 13.2k
Closed
Closed
Copy link
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 editorHelp WantedYou can do thisYou can do this
Milestone
Description
Bug Report
🔎 Search Terms
🕗 Version & Regression Information
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about 13th century Scandinavian architecture
⏯ Playground Link
Playground link with relevant code
💻 Code
type Fruit = "apple" | "banana" | "dragonfruit" | "potato";
declare let fruit: Fruit;
function f() {
switch (fruit) {
case "apple": return;
case "banana": return;
case ""
}
}🙁 Actual behavior
If you trigger the completions on the last case without typing the quotes yet, "apple" and "banana" are filtered out.
But inside the quotes, all the string literals are suggested.
🙂 Expected behavior
Switch case filtering works inside or outside the quotes.
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 editorHelp WantedYou can do thisYou can do this

