#enum values and values itselves being treated as different in generic types

1 messages · Page 1 of 1 (latest)

robust marlinBOT
#
Clauz#2942

Preview:```ts
enum ExampleEnum {
One = 1,
Two = 2,
Three = 3
}

// My goal here is to make the thing prop have the value string if you provide the number and it is three
// Although, if you provide a number which is not 3, you get null
// But if you do not provide the number at all the interface should just suppose you don't know the number so the thing can be both number or null
...```

wraith galleon
#

if you want an explanation it is in code, does anyone know how to fix this?

wraith galleon
#

i fixed this by updating to the beta version