News for hackers. Stuff that matters.
Re:A 'CSS reset' for TypeScript, improving types for common ... by anderskaseorg on Friday March 03, 2023 @01:51AM (#35006612)
You can safely cast an `unknown` to a desired type with a runtime check from a library like Zod (https://zod.dev/). The `unknown` makes sure you don’t forget a check.

There are no comments on this comment yet.