You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The same way we have require-returns and require-param, I think there would be value in a require-throws rule.
Current behavior
Currently, given a function that has a throw keyword, that throws an Error, I have no way to require documenting that the function throws an error using ESLint.
Desired behavior
If a function contains the throw keyword, require having a @throws in the JSDoc for the function.
Alternatives considered
The text was updated successfully, but these errors were encountered:
Motivation
The same way we have
require-returns
andrequire-param
, I think there would be value in arequire-throws
rule.Current behavior
Currently, given a function that has a
throw
keyword, that throws an Error, I have no way to require documenting that the function throws an error using ESLint.Desired behavior
If a function contains the
throw
keyword, require having a@throws
in the JSDoc for the function.Alternatives considered
The text was updated successfully, but these errors were encountered: