web-performance-audit by secondsky/claude-skills
npx skills add https://github.com/secondsky/claude-skills --skill web-performance-audit执行全面的性能审计并实施优化。
| 指标 | 良好 | 需要改进 | 较差 |
|---|---|---|---|
| LCP (最大内容绘制) | <2.5s | 2.5-4s | >4s |
| FID (首次输入延迟) | <100ms | 100-300ms | >300ms |
| CLS (累积布局偏移) | <0.1 | 0.1-0.25 | >0.25 |
| INP (下次绘制交互) | <200ms | 200-500ms | >500ms |
// 使用 web-vitals 库
import { getCLS, getFID, getLCP, getTTFB } from 'web-vitals';
function sendToAnalytics({ name, value, id }) {
console.log({ name, value, id });
}
getCLS(sendToAnalytics);
getFID(sendToAnalytics);
getLCP(sendToAnalytics);
getTTFB(sendToAnalytics);
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
const lighthouse = require('lighthouse');
const chromeLauncher = require('chrome-launcher');
async function runAudit(url) {
const chrome = await chromeLauncher.launch({ chromeFlags: ['--headless'] });
const result = await lighthouse(url, {
port: chrome.port,
onlyCategories: ['performance']
});
await chrome.kill();
return result.lhr;
}
{
"timings": [
{ "metric": "first-contentful-paint", "budget": 1500 },
{ "metric": "largest-contentful-paint", "budget": 2500 }
],
"resourceSizes": [
{ "resourceType": "script", "budget": 150 },
{ "resourceType": "image", "budget": 300 }
]
}
每周安装量
86
代码仓库
GitHub 星标数
90
首次出现
Jan 25, 2026
安全审计
安装于
claude-code73
gemini-cli72
opencode69
cursor69
codex68
github-copilot68
Conduct comprehensive performance audits and implement optimizations.
| Metric | Good | Needs Improvement | Poor |
|---|---|---|---|
| LCP (Largest Contentful Paint) | <2.5s | 2.5-4s | >4s |
| FID (First Input Delay) | <100ms | 100-300ms | >300ms |
| CLS (Cumulative Layout Shift) | <0.1 | 0.1-0.25 | >0.25 |
| INP (Interaction to Next Paint) | <200ms | 200-500ms | >500ms |
// Using web-vitals library
import { getCLS, getFID, getLCP, getTTFB } from 'web-vitals';
function sendToAnalytics({ name, value, id }) {
console.log({ name, value, id });
}
getCLS(sendToAnalytics);
getFID(sendToAnalytics);
getLCP(sendToAnalytics);
getTTFB(sendToAnalytics);
const lighthouse = require('lighthouse');
const chromeLauncher = require('chrome-launcher');
async function runAudit(url) {
const chrome = await chromeLauncher.launch({ chromeFlags: ['--headless'] });
const result = await lighthouse(url, {
port: chrome.port,
onlyCategories: ['performance']
});
await chrome.kill();
return result.lhr;
}
{
"timings": [
{ "metric": "first-contentful-paint", "budget": 1500 },
{ "metric": "largest-contentful-paint", "budget": 2500 }
],
"resourceSizes": [
{ "resourceType": "script", "budget": 150 },
{ "resourceType": "image", "budget": 300 }
]
}
Weekly Installs
86
Repository
GitHub Stars
90
First Seen
Jan 25, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykWarn
Installed on
claude-code73
gemini-cli72
opencode69
cursor69
codex68
github-copilot68
Skills CLI 使用指南:AI Agent 技能包管理器安装与管理教程
46,600 周安装