Create a Basic Framework with Express (Part 1.1)
In Part 1, error handling was created. Let's make it easier to throw errors.
Instead of
let error = new Error('This is a major issue!!')
error.statusCode = 500
throw error
We will make it something like this
throw new ServerError({ message: 'This is...
devlogbook.com1 min read