Appearance
enforce the use of inline code for specific words on comments
--fix
This rule enforces that specific words or phrases are always wrapped in inline code (backticks) when they appear in Comments. This is useful for:
Some examples of incorrect code for this rule:
Some examples of correct code for this rule:
This rule requires configuration of the words that should be wrapped in inline code.
{ "@kazupon/prefer-inline-code-words-comments": [ "error", { "words": ["console.log", "fetch"] } ] }
words
Nothing.
This rule was introduced in @kazupon/eslint-plugin v0.6.0
@kazupon/eslint-plugin
@kazupon/prefer-inline-code-words-comments
--fix
option on the command line can automatically fix some of the problems reported by this rule.Rule Details
This rule enforces that specific words or phrases are always wrapped in inline code (backticks) when they appear in Comments. This is useful for:
Fail
Some examples of incorrect code for this rule:
Pass
Some examples of correct code for this rule:
🔧 Options
This rule requires configuration of the words that should be wrapped in inline code.
words
(required):Related rules
Nothing.
Version
This rule was introduced in
@kazupon/eslint-plugin
v0.6.0Implementation