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
{{ message }}
Repository navigation
"cannot be used to index type" error when indexing NonNullable of a generic type in typescript 4.8 #49681
typeFoo={[key: string]: unknown}typeNullableFoo=Foo|undefinedtypeBar<TextendsNullableFoo>=NonNullable<T>[string]//error on 4.8, no error on 4.7typeBaz<TextendsFoo>=NonNullable<T>[string]// no errortypeQux=NonNullable<NullableFoo>[string]// no error
🙁 Actual behavior
Type 'string' cannot be used to index type 'NonNullable'.(2536)
Activity