Skip to content

Commit 0d37d16

Browse files
committed
Error Handling
1 parent e3bcf8c commit 0d37d16

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

README-zh-CN.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
5. [](#类)
99
6. [测试](#测试)
1010
7. [并发](#并发)
11-
8. [错误处理](#error-handling)
11+
8. [错误处理](#错误处理)
1212
9. [格式化](#formatting)
1313
10. [评论](#comments)
1414

@@ -1981,12 +1981,15 @@ async function getCleanCodeArticle() {
19811981
**[⬆ 返回顶部](#代码整洁的-javascript)**
19821982

19831983

1984-
## **Error Handling**
1984+
## **错误处理**
19851985
Thrown errors are a good thing! They mean the runtime has successfully
19861986
identified when something in your program has gone wrong and it's letting
19871987
you know by stopping function execution on the current stack, killing the
19881988
process (in Node), and notifying you in the console with a stack trace.
19891989

1990+
抛出错误是一件好事情! 他们意味着当你的程序有错时运行时可以成功确认, 并且通过停止执行当前堆栈
1991+
上的函数来让你知道, 结束当前进程(在 Node 中), 在控制台中用一个堆栈跟踪提示你。
1992+
19901993
### Don't ignore caught errors
19911994
Doing nothing with a caught error doesn't give you the ability to ever fix
19921995
or react to said error. Logging the error to the console (`console.log`)

0 commit comments

Comments
 (0)