Commit d036b35
tools: enforce
Add linting rule requiring `throw new Error()` over `throw Error()`.
PR-URL: #3714
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>throw new Error() with lint rule1 parent 38bb0d8 commit d036b35Copy full SHA for d036b35
File tree
Expand file treeCollapse file tree
2 files changed
+38
-0
lines changedOpen diff view settings
Filter options
- tools/eslint-rules
Expand file treeCollapse file tree
2 files changed
+38
-0
lines changedOpen diff view settings
Collapse file
+2Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
87 | 87 | |
88 | 88 | |
89 | 89 | |
| 90 | + |
| 91 | + |
90 | 92 | |
91 | 93 | |
92 | 94 | |
|
Collapse file
tools/eslint-rules/new-with-error.js
Copy file name to clipboard+36Lines changed: 36 additions & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
| 1 | + |
| 2 | + |
| 3 | + |
| 4 | + |
| 5 | + |
| 6 | + |
| 7 | + |
| 8 | + |
| 9 | + |
| 10 | + |
| 11 | + |
| 12 | + |
| 13 | + |
| 14 | + |
| 15 | + |
| 16 | + |
| 17 | + |
| 18 | + |
| 19 | + |
| 20 | + |
| 21 | + |
| 22 | + |
| 23 | + |
| 24 | + |
| 25 | + |
| 26 | + |
| 27 | + |
| 28 | + |
| 29 | + |
| 30 | + |
| 31 | + |
| 32 | + |
| 33 | + |
| 34 | + |
| 35 | + |
| 36 | + |
0 commit comments