Docs: Add rationale to rules #5265
Labels
accepting prs
Go ahead, send a pull request that resolves this issue
documentation
Documentation ("docs") that needs adding/updating
locked due to age
Please open a new issue if you'd like to say more. See https://typescript-eslint.io/contributing.
Before You File a Documentation Request Please Confirm You Have Done The Following...
Suggested Changes
Would be great if the rules consistently explained why something is a rule.
See e.g.
shellcheck
rules, which always include a "Rationale" section:For
typescript-eslint
, the rationales are either unclear (mixed in the what section) or missing (e.g. https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/docs/rules/restrict-template-expressions.md).A rationale would help developers improve their understanding as they stumble upon violations, and would help rule writers clarify their reasoning.
Affected URL(s)
Some examples:
The text was updated successfully, but these errors were encountered: