Session

Types Beyond TypeScript

Everybody seems to be talking about "types" these days. From the TypeScript language to type description utilities such as Zod, developers expect clear descriptions of the shapes of their data. Let's talk about the mindset shift that's happened over the last decade, and where types are taking us over the next one.

1. Thinking in Type(s|Script): How modeling value shapes helps raise predictability and understandability, especially in the wildest and wackiest of project architectures.
2. TypeScript's Limitations: By design, TypeScript can only act as a development-time type system and enforce what that system can represent. We'll want to go over what can't and/or shouldn't be represented in that type system.
3. Raising the Runtime: Moving those type thoughts into your runtime with programmatic frameworks or libraries such as tRPC and Zod.
4. Node.js Specifics: How this "types-first" theory works helps improve common parts of projects in the Node.js ecosystem: REST or RPC endpoints, testing, and documentation.
5. Ecosystem future: where the TC39 types-as-comments proposal will -and won't- take types at a language-level for JavaScript.

By allowing our types to be a reflection of the runtime reality, we embrace types-first thinking in designing code - making our Node.js code more clear to read and update. Hooray, types!

Josh Goldberg

Open Source Developer

Philadelphia, New York, United States

Actions

Please note that Sessionize is not responsible for the accuracy or validity of the data provided by speakers. If you suspect this profile to be fake or spam, please let us know.

Jump to top