Closed
Description
openedon Mar 28, 2023
Bug Report
π Search Terms
suggestions, intellisense, autocomplete
π Version & Regression Information
- This is the behavior in every version I tried
β― Playground Link
Playground link with relevant code
π» Code
declare function test<T extends 'a' | 'b'>(a: { foo: T[] }): void
// Try trigerring the suggestions within the foo array, no suggestions
test({ foo: [<cursor here, ctrl+space>] })
// Try trigerring the suggestions within the foo array, only suggestion is 'a'
test({ foo: ['a', <cursor here, ctrl+space>] })
π Actual behavior
When the array is empty, there is no suggestions at all
When the array has items, the suggestions are restricted to the items already set in the array
π Expected behavior
In both cases, we should have the full list of suggestions 'a' | 'b'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment