@luhanxin/audit
v3.0.0
Published
SEO and accessibility audits for web pages
Maintainers
Readme
@luhanxin/audit
为 Puppeteer 页面提供基础 SEO 检查和 axe-core 无障碍审计。
安装
pnpm add @luhanxin/audit @luhanxin/browser使用
import {auditPage} from '@luhanxin/audit';
const result = await auditPage(page);
console.log(result.seo.issues);
console.log(result.accessibility.violations);SEO 检查包含 title、description、canonical、H1 数量和图片 alt;无障碍检查通过 axe-core 扫描当前页面 DOM。
API
auditSeo(page)auditAccessibility(page)auditPage(page)
构建
pnpm build
pnpm typecheck