Syntax - Tasty Web Development Treats

Converting JS to TypeScript

4 snips
Feb 8, 2023
Discover the fascinating process of converting JavaScript to TypeScript, and learn why this transition can bolster your development confidence. The hosts share personal strategies for effective refactoring and the emotional nuances of the migration journey. Explore the advantages of strict type checking for improving code quality and readability, and hear how tools like GraphQL Code Generator and Zod can aid in streamlining your coding experience. Plus, get practical tips on managing types and enhancing your project with error tracking solutions.
Ask episode
AI Snips
Chapters
Transcript
Episode notes
ADVICE

Prioritize with DepRank

  • Use DepRank to prioritize files for conversion based on dependencies.
  • Start with the most dependent files to minimize cascading errors.
ADVICE

Gradual Conversion

  • Gradually convert files to TypeScript as you work on them.
  • This "as you go" approach is manageable for large projects.
ANECDOTE

Whack-a-Mole Errors

  • Wes sometimes saw error counts increase after fixing a type issue.
  • This happens when the fix reveals other, previously hidden type errors.
Get the Snipd Podcast app to discover more snips from this episode
Get the app