Porting Web SDK from JS into TS
summary
Public JavaScript web SDK is rewritten in TypeScript using yarn/npm, tsc plus webpack, with Mocha and Intern for cross‑browser tests and source maps to preserve stack traces. The SDK is ~13,000 lines and the migration takes three man‑months while bundle size grows 250→800 KB and lines move roughly 11k→12k. Gradual typing lets teams add types after stabilization, compiler error messages prove painful, and generated JS remains readable for consumers.
AI-written summary · about
chapters (22)
- 0:00Intro
- 0:32What was migrated? Web SDK for cloud-based telephony solutions
- 1:52Software Complexity Problem
- 2:11Migration target
- 4:31Types: a trap for errors
- 4:58How traps work
- 8:48Types pros and cons
- 10:04Types cons and pros
- 10:49How we use types at Voximplant
- 11:22What about clients?
- 13:03What about the legacy like jQuery?
- 13:53Will it be fat and slow?
- 14:47What about Creative JavaScript?
- 15:28Gradual transition to TS?
- 17:33Toolchain?
- 18:08Where to get types?
- 18:46How about a build system?
- 19:17Continuous integration?
- 19:50Testing?
- 20:44Best things in practice
- 22:14TypeScript pros and cons
- 24:32Lessons learned by Voximplant
related talks
38mPorting 100K lines of code to TypeScript
31mJavaScript That Scales
24mTypeScript and how I've learned to love the compiler
26mAdopting Typescript at Scale
20mTypeScript and ES6
27mLessons Learned Converting Snyk Codebase to TypeScript
32mIntroducing TypeScript
20mMoving to TypeScript as much as you want
