- Frontend Masters instructor for 9 years
- Developer Platform Lead @ Stripe
- Designs Stripe’s API semantics
- Architect responsible for TypeScript projects like node-stripe, Stripe Shell, and Stripe Workbench
Enterprise software just means software intended for large organizations. How large? For the purposes of this course, let’s say big enough that
- No one person could possibly master the entire codebase
- Multiple teams are involved in the evolution of the project, and they don’t want to be tightly coupled with each other
- If everyone “does their own thing” the codebase (and resultant product) will lose cohesion and become unmanageable
Lots of teams, working on lots of code
Being in this situation requires that we pay extra attention to a few areas.
- Productivity. A broken build, an incompatible dependency, etc… interrupts the work of many people.
- A balance opinionated foundations, and flexibility. There need to be helpful forces that keep the project cohesive, while still providing enough flexibility for creative license, and customizations to meet certain needs in specific areas of the codebase.
- Designing for a long shelf life. Successful large projects are often around for a long time. They need to be able to evolve as things change, and avoid the need for a rewrite every few years
- Managing complexity. Once a codebase gets large enough, managing the interactions between different areas starts to become overwhelming if the architecture is not designed well.
We’ll cover a variety of modern TypeScript development topics that align with these four areas.
- We’ll create a TypeScript library from scratch, with API docs, linting and automated detection of changes to our public API surface!
- We’ll migrate a non-trivial JS codebase to TypeScript, using a low-risk predictable and incremental strategy
- We’ll look at how to keep pace with new TS compiler versions and deal with breaking changes using
- We’ll develop an in-depth understanding of “strictness”, both from the standpoint of compiler settings and lint rules
- We’ll experiment with some exciting new tooling like
swc, a rust-based TypeScript compiler that can run significantly faster
- We’ll use
yarn’s built-in support for workspaces, allowing us to focus in on sub-parts of a large project and work locally
This course is intended for developers who are already familiar with TypeScript as a programming language, and are interested in learning more about how to use it at scale, in libraries, and as a core part of large software projects.
Beyond TypeScript, should be familiar with most of the topics below
- Managing dependencies with
- Linting with
eslintor similar tools
- The concept of
PATCHreleases, as described by semantic versioning.
- Basic use of React.js
- Working with basic shell scripts (or equivalent powershell commands)
As long as you can access the following websites, you should require no further setup
If you’d like to follow along with interactive examples, please install Volta
curl https://get.volta.sh | bash # Linux / macOS onlyvolta install node@lts yarn@^3
Make sure to follow the installation instructions for
volta — both what you see on the website and what you see in the CLI console. Next, clone the git repo for this course github.com/mike-north/typescript-courses, enter the directory, and run
yarn to install all dependencies
git clone https://github.com/mike-north/typescript-coursescd typescript-coursesyarn
most of our work today will be in the
packages/chat folder, but we’ll also create a new package.
In this workshop we’ll be working in the context of a simplified Slack app
The web client for this app lives in
src/, and is roughly organized as
src/ # web clientdata/ # data layerui/ # react componentsutils/ # low-level utilitiesindex.js # entry point
There’s a API and database in this project as well, but we won’t be changing them during the workshop.
server/ # Server-side codesrc/db.json # The database
One thing you absolutely will want to look at is the API examples, which can be found in your