-
Notifications
You must be signed in to change notification settings - Fork 3
Rules
Bhsd edited this page Aug 24, 2025
·
16 revisions
| name | Description |
|---|---|
| bold-header | Bold apostrophes or HTML tags in headers. |
| format-leakage | Format leakage can occur in the TOC when a formatting tag is not closed in the header. |
| fostered-content | Fostered table content that will be moved outside the table. |
| h1 |
<h1> tags should not be used. |
| illegal-attr | Illegal attributes in extension/HTML tags. |
| insecure-style | Insecure inline styles in HTML tags. |
| invalid-css | Invalid inline styles. Require Stylelint. |
| invalid-gallery | Invalid images or image parameters in <gallery> tags. |
| invalid-imagemap | Invalid images or links in <imagemap> tags. |
| invalid-invoke | Invalid module invocation. |
| invalid-isbn | Invalid ISBN. |
| lonely-apos | Lonely apostrophes. |
| lonely-bracket | Lonely square brackets or curly braces. |
| lonely-http | Lonely http:// or https:// or PMID or RFC or ISBN. |
| nested-link | An internal link inside an external link. |
| no-arg |
{{{}}} should only be used for transclusion. |
| no-duplicate | Duplicate attributes, categories, templates parameters, etc. |
| no-ignored | Content ignored by the Wikitext parser. |
| obsolete-attr | Obsolete attributes in HTML5. |
| obsolete-tag | Obsolete HTML tags. |
| parsing-order | Unexpected behaviors due to the parsing order of Wikitext. |
| pipe-like | Plain-text ` |
| table-layout | Inconsistent table layout in terms of row spans and column spans. |
| tag-like | Plain-text < that looks like HTML or extension tags. |
| unbalanced-header | Unbalanced headers, such as starting with == but ending with ===. |
| unclosed-comment | Unclosed HTML comments. |
| unclosed-quote | Unclosed quotes in tag attributes. |
| unclosed-table | Unclosed Wikitext table. |
| unescaped | Unescaped = in external URLs interferes with template parameter parsing. |
| unknown-page | Templates in link targets. |
| unmatched-tag | Unmatched HTML tags. |
| unterminated-url | External URLs containing pipes or full-width punctuation marks. |
| url-encoding | URL encoding in internal links is unnecessary. |
| var-anchor | Anchors that may change due to changes in other parts of the page. |
| void-ext | Void extension tags containing content. |
For each rule, you can configure its severity using 0, 1, or 2:
-
0: Disable the rule. -
1: Warn when the rule is violated. -
2: Error when the rule is violated.
You can also add an additional object for fine-tuning the rule, such as [2, {"key": "value"}]. Read the documentation of each rule for more details.
You can disable specific rules or all rules for a specific range of lines using comments:
<!-- lint-disable rule1, rule2 -->
Content that you want to ignore.
<!-- lint-enable rule1, rule2 -->
Line that you want to ignore.<!-- lint-disable-line rule1, rule2 -->
<!-- lint-disable-next-line rule1, rule2 -->
Line that you want to ignore.对维基文本批量执行语法检查的命令行工具
轻量级的维基模板解析器
维基文本语言服务器协议实现
用于维基文本的 VS Code 扩展
A command-line tool that performs linting on Wikitext in bulk
A lightweight Wikitext template parser
An implementation of the Language Server Protocol for Wikitext
VS Code extension for Wikitext