TS Tricks: Type Guards

added by JavaScript Kicks
3/4/2019 6:57:55 AM

325 Views

With everyone getting excited about Typescript I thought it'd be fun to do a walkthrough of one of my favorite features, type guards. These are type-safe functions that allow us to assert that an argument matches a certain type. The best part is these work at runtime!


0 comments