Creating a TypeScript-based Express project
In this section, we'll build a starting project that we will use to base our server on. We'll manually review and select each dependency and understand what role each will play in our application. When we're done, we will have a strong base for building out our server app.
There are many pre-made project templates that can be used to build Node projects. A common one for TypeScript users is the TypeScript-Node-Starter project from Microsoft. It has a good variety of useful dependencies. Unfortunately, it's geared toward MongoDB users, but our app will use Postgres.
Another project template, from the team that makes Express, is
express-generator. It is a CLI that takes parameters and sets up a base project. However, this template generator is geared toward servers that do server-side HTML using template engines such as
ejs. This would be unnecessary for us since we are creating an API for an SPA application...