跳到正文
Skillpedia
通用编程75k · #2704

frontendchecklist

它能做什么

这项技能运行 Front-End Checklist 命令行工具,依据其规则清单检查网页代码和页面。适合希望在发布前对代码再做一次审查的网页开发者。

适用场景

  • ✓当你编写或修改了 HTML、CSS 或 JavaScript,并希望对其进行检查时。
  • ✓当你想检查一个公开网页的无障碍、SEO 或性能时。
  • ✓当你即将提交代码,并希望对照规则做最后检查时。

技能链接

https://github.com/thedaviddias/Front-End-Checklist/blob/main/packages/cli/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/thedaviddias/Front-End-Checklist/blob/main/packages/cli/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“请按照前端检查清单检查我项目文件夹中的页面,并列出存在的问题。”

每周 5 个新技能,1 分钟读完。

工作原理

智能体会在你的文件或页面链接上运行该工具。它以结构化格式返回发现的问题,并可以查询每条规则的原因和修复方法。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

Front-End Checklist CLI

frontendchecklist checks frontend code against the Front-End Checklist rules. It works offline, prints JSON when its output is piped (which is how you will usually call it), and uses exit codes you can branch on.

Run it with npx -y @frontendchecklist/cli <command> if frontendchecklist is not installed.

When to use it

  • After writing or editing frontend files: frontendchecklist review <paths>.
  • Before committing: git diff --cached | frontendchecklist review -.
  • When the user asks to audit a deployed page: frontendchecklist audit https://....
  • When you need the authoritative guidance for a topic: frontendchecklist search <topic>, then frontendchecklist rule <slug>.
  • For a structured pass (launch, accessibility, SEO, performance): frontendchecklist checklists, then frontendchecklist checklist <slug>.

Commands

Command Purpose
review <paths...|-> Static review of files, directories (walked; vendor dirs skipped), or stdin
audit <https-url> Fetch a public page and review its HTML
search [query] [--focus a,b] [-n 10] Find rules by keyword, technology, or category
rule <slug> Why a rule matters, how to check it, how to fix it
checklists / checklist <slug> Curated checklists and their rules
categories Categories with rule counts
schema Full command reference as JSON

Useful flags: --focus accessibility,seo, --min-priority high, --fail-on high.

Reading results

  • review and audit return { findings: [{ target, rule, title, priority, issue, fix? }], failing }.
  • Exit code 0: fine. 1: findings at or above --fail-on. 2: bad input or runtime error, with { "error": "..." } on stdout.
  • Findings are conservative static heuristics. "No findings" means nothing provable was found, not that the code is clean: follow up with search/rule for areas the heuristics cannot see (rendered contrast, focus order, real performance).

Workflow

  1. frontendchecklist review <changed files> --min-priority medium
  2. For each finding, run frontendchecklist rule <rule> and apply its fix guidance.
  3. Re-run the review until no critical/high findings remain (--fail-on high exits 0).
  4. Mention any remaining medium/low findings to the user instead of silently ignoring them.
常见问题

它需要网络连接吗?

只有在审查线上 URL 时才需要。这项技能说明代码审查可以离线进行。

我怎样了解某条规则为什么重要?

这项技能提供一条命令,可以解释规则的原因以及修复方法。

它涵盖哪些代码类型?

这项技能列出了 HTML、CSS、JavaScript,以及 JSX、Vue、Svelte 和 Astro 等框架。

详情

作者的原始描述

Review frontend code and live pages against the Front-End Checklist (380+ rules for accessibility, performance, SEO, security, HTML, CSS, JavaScript, images, i18n, privacy, testing) using the `frontendchecklist` CLI. Use when writing, reviewing, or shipping HTML/CSS/JS/JSX/TSX/Vue/Svelte/Astro code, before a commit or PR, or when asked to audit a public URL.

repo: thedaviddias/Front-End-Checklist

热度

GitHub 星标
75k
排名
#2704
许可证
MIT
更新时间
2026/10/31

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能