TypeScript

Learn how TypeScript can help you make less buggy apps.

Intro talk

https://fac-slides.netlify.app/slides/typescript/

Learn

Start by reading the short TS for JS programmers intro.

Then complete as much of Execute Program's TS course as it will allow.

Finally move on to the TS Handbook. This is quite long so just skim "The Basics" and "Everyday Types" at first. It's generally better to look up specific things when you need them rather than trying to front-load all the knowledge.

Project

You have two choices (depending on how much time you have):

  1. Create a React app from scratch using TS

  2. Refactor one of your previous React apps using TS

Either way please document anywhere you have to amend your code because TS caught a type error. It will be interesting to hear about how you had to program differently based on TS' feedback.

You may find this React + TS cheatsheet helpful.

Project tooling

Both Create React App and Vite have built in support for TypeScript. Make sure you click through to their respective docs as there are some nuances/differences.

Note: neither require you to run the TS compiler yourself—you'll be using their normal start/dev/build commands.

Help each other

You don't have mentors to ask for help, so try to help each other. Use your Discord channels to stay in touch and solve problems.

Last updated