Category: Express

Express JavaScript

TypeScript Express tutorial #5. MongoDB relationships between documents

This entry is part 5 of 7 in the TypeScript Express tutorial

Today we dive into MongoDB relationships between documents. To do it we use Mongoose and the populate feature. As always, the code that we cover here is available in the express-typescript repository. You’re welcome to give it a star. MongoDB relationships between documents The fact is that MongoDB is a NoSQL database. It means that it […]

Express JavaScript

TypeScript Express tutorial #4. Registering users and authenticating with JWT

This entry is part 4 of 7 in the TypeScript Express tutorial

Today we cover an essential part of almost every application: registering users and authenticating them. To implement it, we use JSON Web Tokens (JWT). Instead of getting help from libraries like Passport, we build everything from the ground up to get the best understanding of how it works. As always, all of the code is […]

Express JavaScript

TypeScript Express tutorial #3. Error handling and validating incoming data

This entry is part 3 of 7 in the TypeScript Express tutorial

Since not always everything goes perfectly, you need to expect the unexpected. To prepare for that, we cover TypeScript Express error handling and incoming data validation. Just as before, the repository for the tutorial is mwanago/express-typescript. If you find it helpful, feel free to give it a star. Express Error handling In the previous part of the […]