You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
typeTest<Textends{example: "yes"|"no";}>=T["example"];constfoo: Test<{example: ""}>="yes";// ^^ <- No completions available here.// As a string literal there should be concrete completions for "yes" | "no".// The compiler does however recognize the correct type with type error:// `Type '{ example: ""; }' does not satisfy the constraint '{ example: "yes" | "no"; }'.`
🙁 Actual behavior
There are no type completions hints for string literal unions inside generic objects.
🙂 Expected behavior
There should be type completion hints with the appropriate type variants. In the example above, with the completions should be yes and no.
The text was updated successfully, but these errors were encountered:
Bug Report
🔎 Search Terms
🕗 Version & Regression Information
⏯ Playground Link
https://tsplay.dev/WGdLJw
💻 Code
🙁 Actual behavior
There are no type completions hints for string literal unions inside generic objects.
🙂 Expected behavior
There should be type completion hints with the appropriate type variants. In the example above, with the completions should be
yes
andno
.The text was updated successfully, but these errors were encountered: