/error-handling-typescript

Error handling strategy for Typescript

Primary LanguageTypeScript


Logo

Error Handling in Typescript

An strategy for error handling in typescript.
Explore the docs »

Table of Contents
  1. About The Project
  2. Getting Started
  3. License
  4. Contact
  5. Acknowledgments

About The Project

The error-handling project it is an attempt to supply an strategy for error handling in typescript.

We all know that the main challenges with error handling are:

  • When to use and where to add try ... catch statement.
  • How to deal with known and unknown errors.
  • What about logging unknown errors rather than using try ...catch?

The error-handling provider offer a clean, self-contained solution for capturing known errors within your application, and all that in one single line of code.

For unknown error I recommend you to use a logger solution detailing the error and its context.

(back to top)

Built With

This project were built using the following technologies:

  • Typescript
  • ts-node-dev
  • tsconfig-paths
  • uuidv4 for unique identifiers

(back to top)

Getting Started

To use this example you need to:

  1. Install the project dependencies using yarn or npm: yarn install or npm install
  2. Run the project: yarn start or npm start

Prerequisites

Intermediate knowledge of typescript is required. Good knowledge on software architecture is also helpful, and experience with error handling paint points.

License

Distributed under the MIT License.

(back to top)

Contact

Twitch - id_akira

Linkedin - Richard Zampieri

(back to top)

Acknowledgments

I always dedicated most of my accomplishments to the community, specially to the people on the Twitch channel that are always questioning the status quo.

(back to top)