Re:A lightweight TypeScript library for assertion-based runt...
by ale on Monday August 25, 2025 @01:05PM
(#45016068)
Libraries like these are meant for runtime validation. I agree though. I prefer to use the compiler itself (tsc --noEmit) than recreating the validation logic.
[ Parent
| on HN ]
Re:A lightweight TypeScript library for assertion-based runt...
by mirekrusin on Monday August 25, 2025 @03:48PM
(#45018168)
It doesn't compete with static type system, it complements it. Static type system in typescript can't do anything with unknown/any values that are crossing i/o boundary - they require runtime assertion to bring them into statically typed, safer world.