1
1
<div align =" center " >
2
2
3
- <img width =" 814 " src =" https://raw.githubusercontent.com/kabeep/exception/master/docs/images /logo-dark.png" alt =" logo-dark " >
3
+ <img width =" 814 " src =" assets /logo-dark.png" alt =" logo-dark " >
4
4
5
5
Exception is a custom error library for Node.js that provides a more flexible and customizable way of handling errors.
6
6
@@ -17,9 +17,7 @@ English | [简体中文](README.zh-CN.md)
17
17
18
18
![ Alt] ( https://repobeats.axiom.co/api/embed/92224457b32c02414aa34c21a923f17f95019cd4.svg " Repobeats analytics image ")
19
19
20
- <img width =" 814 " src =" https://raw.githubusercontent.com/kabeep/exception/master/docs/images/Inheritance-and-prototype-chain.png " alt =" inheritance-tree " >
21
-
22
- Inheritance and the prototype chain
20
+ <img width =" 814 " src =" assets/preview.png " alt =" preview.png " >
23
21
24
22
</div >
25
23
@@ -37,6 +35,8 @@ The goal of Exception is to transform unexpected occurrences into anticipated ou
37
35
It allows Error objects to throw exception and stack information in a more aesthetically pleasing and intuitive manner,
38
36
and can also serve as Notify to output critical information in workflows.
39
37
38
+ <img width =" 600 " src =" assets/Inheritance-and-prototype-chain.png " alt =" inheritance-tree " >
39
+
40
40
## ⚙️ Installation
41
41
42
42
``` bash
@@ -57,7 +57,7 @@ pnpm add @kabeep/exception
57
57
58
58
[ example] ( example/default.ts )
59
59
60
- ![ Plain-text-or-Error-object] ( https://raw.githubusercontent.com/kabeep/exception/master/docs/images /Plain-text-or-Error-object.png)
60
+ ![ Plain-text-or-Error-object] ( assets /Plain-text-or-Error-object.png)
61
61
62
62
``` javascript
63
63
import Exception from ' @kabeep/exception' ;
@@ -73,7 +73,7 @@ throw new Exception(new Error('Argument example'));
73
73
74
74
[ example] ( example/promise.ts )
75
75
76
- ![ Using-in-Asynchronous-Contexts] ( https://raw.githubusercontent.com/kabeep/exception/master/docs/images /Using-in-Asynchronous-Contexts.png)
76
+ ![ Using-in-Asynchronous-Contexts] ( assets /Using-in-Asynchronous-Contexts.png)
77
77
78
78
``` javascript
79
79
import Exception from ' @kabeep/exception' ;
@@ -89,7 +89,7 @@ import Exception from '@kabeep/exception';
89
89
90
90
[ example] ( example/stylish.ts )
91
91
92
- ![ Custom-Styles] ( https://raw.githubusercontent.com/kabeep/exception/master/docs/images /Custom-Styles.png)
92
+ ![ Custom-Styles] ( assets /Custom-Styles.png)
93
93
94
94
``` javascript
95
95
import Exception from ' @kabeep/exception' ;
@@ -106,7 +106,7 @@ console.log(
106
106
107
107
[ example] ( example/extends.ts )
108
108
109
- ![ Custom-Exceptions] ( https://raw.githubusercontent.com/kabeep/exception/master/docs/images /Custom-Exceptions.png)
109
+ ![ Custom-Exceptions] ( assets /Custom-Exceptions.png)
110
110
111
111
``` javascript
112
112
import Exception from ' @kabeep/exception' ;
@@ -128,7 +128,7 @@ console.log(warn);
128
128
129
129
[ example] ( example/extends.ts )
130
130
131
- ![ Print-Key-Information] ( https://raw.githubusercontent.com/kabeep/exception/master/docs/images /Print-Key-Information.png)
131
+ ![ Print-Key-Information] ( assets /Print-Key-Information.png)
132
132
133
133
``` javascript
134
134
import Exception from ' @kabeep/exception' ;
@@ -217,4 +217,4 @@ Contributions via Pull Requests or [Issues](https://github.com/kabeep/exception/
217
217
218
218
## 📄 License
219
219
220
- This project is licensed under the MIT License. See the [ LICENSE] ( LICENSE ) file for details.
220
+ This project is licensed under the MIT License. See the [ LICENSE] ( LICENSE ) file for details.
0 commit comments