I don't know how to reproduce the following in the svelte-5 REPL because it doesn't recognize enum
from the same file:
<script lang="ts"> enum Pro { ZERO, ONE, TWO } let pros: Pro = $state(Pro.ZERO); const again: boolean = $derived(pros == Pro.ONE || pros == Pro.TWO);</script>
I'm getting the typescript error:
This comparison appears to be unintentional because the types 'Pro.IDLE' and 'Pro.ONE' have no overlap. ts(2367)
Why?