Building a universal TypeScript library in 2025

I’m sharing best practices on building a truly cross-platform / universal TypeScript library in 2025. TypeScript compiles to JavaScript which runs everywhere, so that should be easy, right? For a simple library, sure, but when you need access to runtime APIs, things become more problematic. I’ll touch on how to use TypeScript project references to achieve lockdown of runtime types and fast incremental builds and how to use static declarations via export conditions instead of imperative checks at runtime, making bundlers happier about the awesome library you’ve built.

Rate this session on Joind.in

Share

Session info:

Speaker: Kræn Hansen

Senior Software Engineer on the Realm JS team at MongoDB at MongoDB

Date: 21 March 2025

Time: 11:50 - 12:20

Relevant tags:
Backend Typescript

See all speakers

See all videos