Next Steps

View saved

What you can do now

  • Install and run tsc
  • Annotate primitives, interfaces, unions, and functions
  • Narrow unions safely and avoid casual any
  • Organize files with modules and a basic tsconfig

Practice ideas

Convert a small JavaScript script to TypeScript, add interfaces for your data, and turn on strict. Fix every error the compiler reports.

Common traps

  • Using any to silence errors instead of modeling data
  • Forgetting null checks on DOM queries
  • Mismatching module settings between tsconfig and Node
  • Editing emitted .js instead of the .ts source

Where to go next

  • Deeper generics and conditional types
  • Enums vs union literals
  • Frontend frameworks with TypeScript (React, Vue, Svelte)
  • API typing with zod or OpenAPI-generated clients
  • Declaration files (.d.ts) for plain JavaScript libraries

Comments

One comment per signed-in account. Comments are saved with this page’s URL.