wechat-html-check-no-div

Validates WeChat article HTML against div, style, script, and chart-fence rules.

5|1|Updated Jul 31, 2026
One-click install
npx skills add https://github.com/shiker1996/wechat-editroom --skill wechat-html-check-no-div-shiker1996
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: wechat-html-check-no-div
Source: https://github.com/shiker1996/wechat-editroom/tree/main/skills/wechat-html-check-no-div
Command: npx skills add https://github.com/shiker1996/wechat-editroom --skill wechat-html-check-no-div-shiker1996

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? WeChat Official Account publishing rejects or breaks HTML containing div tags, style blocks, scripts, event handlers, and unprocessed chart fences, and catching these issues by eye before publishing is error-prone. ## Core Features & Use Cases - Deterministic HTML Gate: Runs a Node.js script that checks for div open tags, style/link stylesheet blocks, scripts, on* event handlers, iframes, forms, and unprocessed Mermaid/ECharts fences. - Machine-Readable Output: Returns a JSON result like {"valid":true,"issues":[]} with exit code 0 on success, enabling automated retry loops by an orchestrator. - Use Case: After normalizing a final WeChat article HTML file and before generating the copy-page preview, run the gate on article.ai.html; if issues are reported, the orchestrator can re-invoke the normalizer up to two rounds. ## Quick Start Ask the assistant to run the wechat-html-check-no-div gate on your final article.ai.html file and report any validation issues found.

Frequently Asked Questions about wechat-html-check-no-div

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I check WeChat article HTML for invalid tags before publishing?

Run the check-html.mjs script with Node.js against your final HTML file, for example node scripts/check-html.mjs article.ai.html. It exits with code 0 and outputs {"valid":true,"issues":[]} when the document passes all checks.

What HTML elements are not allowed in WeChat Official Account articles?

This gate flags div open tags, style tags, stylesheet links, script tags, on* event handlers, iframes, forms, and unprocessed Mermaid or ECharts code fences. It also detects fixed pixel dimensions on flow tags and content outside the html element.

Does this HTML checker modify or fix the article file?

No, the skill only inspects the HTML and reports issues as JSON; it never rewrites content. Fixing is delegated to a separate normalizer step, which the orchestrator may retry up to two rounds.

Why does the HTML check report content_after_html or content_before_html?

These issues appear when non-whitespace text exists before the doctype/html start or after the closing </html> tag. Remove the stray content so the document contains only a single clean HTML document.

What dependencies are required to run the HTML validation script?

The script uses only Node.js built-in modules (fs and path), so no npm packages need to be installed. Any recent Node.js runtime can execute it directly from the command line.