enteleform
enteleform
Explore posts from servers
CC#
Created by enteleform on 12/31/2022 in #help
❔ Is there an equivalent feature to TypeScript's Indexed Access Types?
e.g.
type Example<T> = {
items: T[]
}

type StringItems = Example<string>["items"]
// string[]

function getStringItem(stringItems:StringItems){
// ...
}
type Example<T> = {
items: T[]
}

type StringItems = Example<string>["items"]
// string[]

function getStringItem(stringItems:StringItems){
// ...
}
7 replies