Currently implementing something for fastify, which can be simplified to:
const b: 'GET' | 'POST' = 'GET'
expectError(b === 1)
✖ 534:4 Found an error that tsd does not currently support (ts2367), consider creating an issue on GitHub.
✖ 534:16 This comparison appears to be unintentional because the types string | (string & Record<never, never>) | HTTPMethods[] and number have no overlap.
And yes I could do
expectAssignable<string>(b)
but it is less expressive imho
Currently implementing something for fastify, which can be simplified to:
And yes I could do
but it is less expressive imho