Enable the unicorn/throw-new-error linting rule
For more information refer to https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/throw-new-error.md. This didn't require any changes because we already do this correctly, but it ensures that new code remains consistent and explicit.
This commit is contained in:
parent
ad95df2214
commit
318433b2d8
@ -79,6 +79,7 @@
|
|||||||
"unicorn/prefer-string-replace-all": "error",
|
"unicorn/prefer-string-replace-all": "error",
|
||||||
"unicorn/prefer-string-starts-ends-with": "error",
|
"unicorn/prefer-string-starts-ends-with": "error",
|
||||||
"unicorn/prefer-ternary": ["error", "only-single-line"],
|
"unicorn/prefer-ternary": ["error", "only-single-line"],
|
||||||
|
"unicorn/throw-new-error": "error",
|
||||||
|
|
||||||
// Possible errors
|
// Possible errors
|
||||||
"for-direction": "error",
|
"for-direction": "error",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user