flow typed - How can I express the type of a map, where one of the keys has a different type? -
basically want this:
type thing = { description: string } & { [key:string|number]: thing }
but above results in key description being described 2 incompatible types. tried intersection $diff remove description second part, didn't help.
how can describe map type single key special cased?
Comments
Post a Comment