Here is how I am attempting to define a specific type:
type Response = {
type: 'a',
value: string
} | {
type: ???, // any other string except 'a'
value: number
}
Do you think this can be done?
I experimented with the following code:
type OtherStrings = Exclude<string, 'a'>
However, it did not yield the results I was hoping for.