Communitygithub.com

发布前质量检查

对网站进行发布前的质量检查,涵盖性能、可访问性、SEO基础、表单、跨设备行为及内容,并根据严重程度对发现的问题进行排序,同时提供修复建议。当有人说网站“准备上线”、“即将发布”、“能帮我检查下网站吗”或需要进行QA、网站审计、Lighthouse式审查,或想了解页面速度慢或评分低的原因时,可使用此技能。

发布前质量检查 是什么?

Launch QA 是一项用于网站发布前质量检查的技能,能够系统地识别并优先处理关键问题。它会自动执行 WebCraft CLI 或 MCP 的 `audit_site` 工具,对线上或本地构建文件进行可衡量的检查,如 robots.txt、站点地图、重定向、404 页面和链接状态。该技能将发现的问题分类为“阻止程序”、“应修复”和“微调”,并生成一份结构化报告,涵盖功能与内容、性能、可访问性、SEO、跨设备兼容性、安全及运维等八个关键领域。它强调基于测量而非主观判断,并对无法自动检查的方面(如真实设备测试、表单提交验证)进行标注。此技能适用于 Cursor、Claude Code 及其他命令行或 MCP 环境,通过提供明确的“就绪/阻断后就绪/未就绪”评估结论,让网站所有者立即了解状况。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/imperfec-t/webcraft/tree/HEAD/skills/launch-qa

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

发布前质量检查 (Launch QA)

找出会让网站所有者尴尬或导致他们失去潜在客户的问题,按优先级排序并提出修复建议。列出四十个同等重要的微小问题并无用处;三个阻塞性问题加上少数次要问题才是关键。

如何运行

  1. 确定你可以检查的内容:在线 URL、源文件,或两者皆有。说明哪些检查你无法执行(例如真实设备测试或表单送达),而不是标记为“通过”。

  2. 如果 webcraft CLI 可用,先运行它进行可衡量的检查(或调用 audit_site MCP 工具):

    webcraft audit https://example.com --pages 10     # 线上站点:还会检查 robots、站点地图、重定向、404、链接
    webcraft audit ./dist                             # 本地构建文件夹
    webcraft audit ./dist --json --fail-on blocker    # CI:遇到阻塞性问题则退出码为 1
    

    它会生成下方包含“未检查”列表的报告模板。在重复报告令人惊讶的发现之前,请先验证其准确性。然后将你的精力投入到它无法发现的问题上:渲染、键盘导航、真实设备、内容准确性。

  3. 按以下区域逐项检查。优先使用测量而非主观判断:运行页面、阅读标记、计算字节。

  4. 将每个发现分类:

    • 阻止程序: 功能损坏、核心内容不可访问、表单无法送达、错误或占位符内容、网站本应可被索引却不可索引。
    • 应修复: 对性能、可访问性或搜索外观造成可衡量的损害。
    • 微调: 微小不一致之处。
  5. 使用末尾的模板进行报告。

功能与内容

  • 每个链接和按钮都指向真实地址。不存在 #、lorem ipsum、模板残留内容或测试电子邮件地址。
  • 表单:必要的验证、清晰的错误信息、成功状态、垃圾邮件保护,以及能真正投递到正确收件箱的测试提交。
  • 电话号码使用 tel:,电子邮件使用 mailto:,且均为正确的号码和地址(检查页眉和页脚之间的号码是否不一致)。
  • 存在 404 页面并链接到首页。
  • 必要时提供法律页面:隐私政策、条款、如果使用追踪功能则提供 Cookie 通知。
  • 版权年份和业务信息是最新且一致的。

性能

目标(在4G网络下的中端手机上):LCP 低于 2.5 秒,INP 低于 200 毫秒,CLS 低于 0.1。

  • 图片:现代格式(WebP 或 AVIF),尺寸适应显示大小,设置了 width 和 height,折叠线以下使用 loading="lazy",LCP 图片预加载且不使用懒加载。
  • 视频:海报图像,不自动播放声音,压缩,如果仅作为装饰,则在小屏幕上不加载。
  • 字体:最多两种字体簇,font-display: swap,预加载首屏文件。
  • CSS 和 JS:压缩,尽可能延迟加载,无未使用的库(一个滑块库仅用于一张静态图片是常见问题)。
  • 第三方脚本:每个脚本都有其合理用途。聊天组件和追踪器经常是 LCP 和 INP 的元凶。
  • 服务器端启用缓存和压缩。

可访问性

  • 只有一个 h1;标题级别不跳级。
  • 所有有意义的图片都有 alt 文本;装饰性图片使用空 alt=""。
  • 文本对比度至少为 4.5:1(大文本为 3:1)。首先检查图片上的文本和灰色文本。
  • 所有内容可通过键盘操作:可见的焦点环、逻辑顺序、菜单和手风琴可操作、无焦点陷阱。
  • 表单字段关联了 <label> 元素;错误信息需被宣告,不能仅通过颜色显示。
  • 尊重 prefers-reduced-motion;无闪烁内容;自动播放的动画可暂停。
  • <html> 上设置了 lang 属性;页面在 200% 缩放比例下正常运行。

SEO 基础

  • 每页有唯一的 <title>(50 到 60 个字符)和元描述(约 150 个字符)。
  • 设置了规范 URL;域名只有一个版本(https,带或不带 www),其他版本重定向到此版本。
  • robots.txt 未阻止网站,不存在来自预演环境的残留 noindex,存在 XML 站点地图。
  • Open Graph 标题、描述和图像(1200x630,通过 https 提供),以便共享链接显示正常。
  • 适当的地方使用结构化数据(Organization 或 LocalBusiness、FAQ、Article),且验证有效。
  • 描述性链接文本而非“点击此处”;使用清晰的 URL。

跨设备

  • 宽度 320、390、768、1024、1440:无水平滚动、无文本重叠、点击目标至少 44px。
  • 当前版本的 Chrome、Safari、Firefox 和 Edge;特别注意 iOS Safari 中的 vh 单位、固定定位和视频自动播放。
  • 如果 JavaScript 失败,动画不会隐藏内容。

安全与运维

  • 全站 HTTPS,无混合内容。
  • CMS、主题和插件已更新;删除未使用的插件和主题;无默认管理员用户名。
  • 定期备份且至少完成一次恢复测试。
  • 已关联分析和搜索控制台,并在要求时处理用户同意。
  • 存在 Favicon 和触摸图标。

报告模板

# 发布前检查:[网站]   检查日期:[日期]   范围:[已检查和未检查的内容]

结论:就绪 / 修复阻塞问题后可就绪 / 未就绪

## 阻止程序
1. [问题描述] — [位置] — [修复方法]

## 应修复
...

## 微调
...

## 未检查
- [检查项] — [原因及所有者如何自行检查]

每条发现保持一行描述问题,一行描述位置,一行描述修复方法。首先给出结论,以便所有者立即了解当前状况。

Individual skills in this repo

This repo contains 8 individual skills — each has its own dedicated page.

design-tokens

Create a website's visual system as CSS custom properties, covering color palette, typography scale, spacing, radius and shadows, with contrast checked. Use this whenever someone asks for a color scheme, a palette from one brand color, font pairing, a type scale, "make it look consistent", dark mode, a rebrand of an existing site into new colors, or starts a build with no defined styles.

hero-section

Design and build the hero (first screen) of a website, including headline layout, media treatment, CTA, proof badge, marquee and entrance animation. Use this whenever someone asks for a hero section, a landing page header, "the top of my homepage", a cinematic or animated intro, a video background, a text marquee, or says their first screen looks plain or generic.

homepage-blueprint

Plan the section structure and content slots of a homepage for an agency, freelancer, studio or service business before any design or code. Use this whenever someone asks "what sections should my homepage have", "plan my website", "structure a landing page for my business", wants a wireframe or sitemap for a service site, or starts building a homepage without a clear outline.

responsive-layout

Build page layouts that work from phones to wide desktops using CSS grid, flexbox, container queries and fluid sizing, including card grids, bento grids, split sections, sticky sidebars and navigation that collapses. Use this whenever someone says their site "breaks on mobile", asks for a responsive grid, a bento layout, a mobile menu, fixing horizontal scroll or overflow, or is laying out any multi-column section.

scroll-motion

Add scroll-driven and entrance animation to a website with GSAP, ScrollTrigger and Lenis, including reveals, parallax, pinned sections, horizontal scroll, line drawing, counters and preloaders. Use this whenever someone wants a site to "feel premium", asks for smooth scrolling, scroll animations, parallax, text reveals, a pinned or sticky scroll section, an animated preloader, or names GSAP, ScrollTrigger, Lenis, Locomotive or AOS.

site-teardown

Analyze a live website and turn it into a section-by-section build brief that another person or AI can rebuild from, with brand name, colors, fonts and images swapped for placeholders. Use this whenever someone shares a URL and says "analyze this site", "make something like this", "give me a prompt to build this", "recreate this effect", "clone the layout with my branding", or asks how a page's animation or structure works, even if they never say "teardown".

website-workflow

Plan and sequence a whole website build, from structure through design, code, WordPress and launch, by routing each stage to the right webcraft skill. Use this when someone asks to "build me a website", "design my site from scratch", "redo our homepage", wants an end-to-end plan for a marketing, agency, studio or service site, or the request spans more than one of structure, look, layout, motion, CMS and QA.

wordpress-theme-build

Turn a static HTML/CSS/JS design into a custom WordPress theme that the client can edit, covering theme structure, theme.json, enqueueing scripts, block patterns, custom post types and editable content. Use this whenever someone wants to convert a design or static site to WordPress, build a custom or block theme, make sections editable in Gutenberg, add GSAP or other scripts to a theme properly, or asks why their theme edits are lost or their content is hard-coded.

相关技能