-
- -Toru Nagashima - - |
唯然 + |
+
+ +Nitin Kumar + |
+ if some problems reported by the rule are automatically fixable by the --fix
command line option
+
+ if the "extends": "eslint:recommended"
property in a configuration file enables the rule.
+
+ if some problems reported by the rule are manually fixable by editor suggestions +
++ {{ params.supporting_text | safe }} +
+ {% if params.buttons %} +
+ The "extends": "eslint:recommended"
property in a configuration file enables this rule
+
+ Some problems reported by this rule are automatically fixable by the --fix
command line option
+
+ Some problems reported by this rule are manually fixable by editor suggestions +
+
+ if the "extends": "eslint:recommended"
property in a configuration file enables the rule.
+
+ if some problems reported by the rule are automatically fixable by the --fix
command line option
+
+ if some problems reported by the rule are manually fixable by editor suggestions +
+{{ rule }}
{% endfor %}
+{%- endmacro -%}
diff --git a/docs/src/_includes/components/rule.macro.html b/docs/src/_includes/components/rule.macro.html
new file mode 100644
index 000000000000..ec8722e976b7
--- /dev/null
+++ b/docs/src/_includes/components/rule.macro.html
@@ -0,0 +1,47 @@
+{% from 'components/rule-list.macro.html' import ruleList %}
+
+{%- macro rule(params) -%}
++ {{ params.name }} + deprecated +
+ {%- if params.replacedBy|length -%} +Replaced by {{ ruleList({ rules: params.replacedBy }) }}
+ {%- else -%}{{ params.description }}
+ {%- endif -%} + {%- elseif params.removed == true -%} ++ {{ params.name }} + removed +
+ {%- if params.replacedBy -%} +Replaced by {{ ruleList({ rules: params.replacedBy }) }}
+ {%- else -%}{{ params.description }}
+ {%- endif -%} + {%- else -%} + {{ params.name }} +{{ params.description }}
+ {%- endif -%} +❌
+ {%- else -%} ++ ✅ Extends +
+ {%- endif -%} + ++ 🛠 Fix +
++ 💡 Suggestions +
+Results will be shown and updated as you type.
+This rule was introduced in ESLint v{{added_version}}{% if removed_version%} + and removed in v{{removed_version}}{% endif %}.
+ {% endset %} + + {% set all_content = [all_content, version_content] | join %} + {% endif %} + + {% if further_reading %} + {% set further_reading_content %} +{{ rule_meta.docs.description | markdown | safe }}
+ {{ ruleCategories({ + index: id, + recommended: rule_meta.docs.recommended, + fixable: rule_meta.fixable, + hasSuggestions: rule_meta.hasSuggestions + }) }} + {% endif %} + + {% include 'components/docs-toc.html' %} + + {{ all_content | safe }} +