Consider the object below:
const myObject = {
one: {
fixed: {
a: 1
}
},
two: {
fixed: {
b: true
}
},
three: {
fixed: {
c: 'foo'
}
}
}
Is there a way to use this object to define a type similar to the following?
type MyUnionType = {
a: number
b: boolean
c: string
}
If so, how can it be achieved?