Hi guys,
I'm trying to map field types to the types of their prefixed versions, eg
type Name = {
firstNameEnabled: boolean
}
type FirstName = {
enabled: Name['firstNameEnabled']
}
Except that FirstName's properties are inferred from Name, so if I added firstNameFoo to Name, foo is automatically inferred for FirstName.
I'm getting "Type '${S}${Capitalize<key>}' cannot be used to index type 'F'" but I can't fathom why, any ideas?
Thanks!