Skip to content

tag-pattern ​

Require tags to match a configured regular expression.

CategoryRecommendedSafe autofixDefault options
tagsnono{"pattern":"^@[a-z0-9][a-z0-9_-]*$"}

Requires tag names to match a regular expression.

Configuration ​

json
{ "rules": { "tag-pattern": ["error", {"pattern":"^@[a-z0-9][a-z0-9_-]*$"}] } }

Triggered by ​

text
@BadTag

Released under the MIT License.