Skip to main content

comment-word-disallowed-list

Specify a list of disallowed words within comments.

 /* words within comments */
/** ↑ ↑ ↑
* These three words */
warning

Comments within selector and value lists are currently ignored.

The message secondary option can accept the arguments of this rule.

Options

Array<string>

["array", "of", "words", "/regex/"]

Given:

{
"comment-word-disallowed-list": ["/^TODO:/", "badword"]
}

The following patterns are considered problems:

/* TODO: */
/* TODO: add fallback */
/* some badword */

The following patterns are not considered problems:

/* comment */