frontend-developer-skill by 404kidwiz/claude-supercode-skills
npx skills add https://github.com/404kidwiz/claude-supercode-skills --skill frontend-developer-skill提供完整的前端开发专业知识,用于使用现代框架(React、Vue、Next.js)构建生产就绪的 Web 应用程序,包括全面的工具链设置、状态管理模式、测试基础设施和性能优化策略。
在以下情况调用此技能:
在以下情况请勿调用:
backend-developerdatabase-optimizerdevops-engineerui-designer广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
前端框架选择
├─ 新项目 (greenfield)
│ ├─ 需要 SEO + 服务器端渲染
│ │ ├─ 团队熟悉 React → Next.js 14+
│ │ ├─ 团队熟悉 Vue → Nuxt.js 3+
│ │ └─ 团队灵活 → Next.js (生态系统优势)
│ │
│ ├─ 无 SSR 要求的 SPA
│ │ ├─ 有 React 经验 → React 18+ (Vite)
│ │ ├─ 有 Vue 经验 → Vue 3 (Vite)
│ │ └─ 企业级/复杂表单 → Angular 15+
│ │
│ └─ 静态站点 (博客、文档)
│ └─ Astro、Next.js SSG 或 Vite + React
│
└─ 现有项目
└─ 继续使用现有框架 (保持一致性)
| 场景 | 库 | 包大小 | 用例 |
|---|---|---|---|
| 简单的局部状态 | useState, useReducer | 0 KB | 组件级状态 |
| 共享状态 (2-3 个组件) | Context API | 0 KB | 主题、身份验证、简单的全局状态 |
| 中型应用 (<10 个切片) | Zustand | ~1 KB | 大多数应用,良好的开发者体验 |
| 大型应用 (10+ 个切片) | Redux Toolkit | ~11 KB | 企业级应用,时间旅行调试 |
| 服务器状态 | TanStack Query | ~12 KB | API 数据、缓存 |
样式决策
├─ 快速原型设计 → Tailwind CSS
├─ 组件库 → Radix UI + Tailwind
├─ 动态主题 → CSS-in-JS (Styled Components, Emotion)
├─ 大型团队 → CSS Modules 或 Tailwind + 设计令牌
└─ 性能关键 → 纯 CSS / SCSS
function useFetch<T>(url: string) {
const [data, setData] = useState<T | null>(null);
const [loading, setLoading] = useState(true);
const [error, setError] = useState<string | null>(null);
useEffect(() => {
fetch(url)
.then(res => res.json())
.then(setData)
.catch(setError)
.finally(() => setLoading(false));
}, [url]);
return { data, loading, error };
}
// 展示组件 (dumb)
const UserList = ({ users, onUserClick }: UserListProps) => (
<ul>
{users.map(user => (
<li key={user.id} onClick={() => onUserClick(user.id)}>
{user.name}
</li>
))}
</ul>
);
// 容器组件 (smart)
const UserListContainer = () => {
const { users, fetchUsers } = useUsers();
useEffect(() => fetchUsers(), [fetchUsers]);
return <UserList users={users} onUserClick={handleClick} />;
};
状态未更新
组件未重新渲染
性能问题
测试失败
每周安装
121
仓库
GitHub 星标
43
首次出现
2026年1月24日
安全审计
安装于
opencode98
codex93
gemini-cli90
cursor85
github-copilot81
claude-code81
Provides complete frontend development expertise for building production-ready web applications with modern frameworks (React, Vue, Next.js), comprehensive tooling setup, state management patterns, testing infrastructure, and performance optimization strategies.
Invoke this skill when:
Do NOT invoke when:
Frontend Framework Selection
├─ New Project (greenfield)
│ ├─ Needs SEO + server-side rendering
│ │ ├─ Team knows React → Next.js 14+
│ │ ├─ Team knows Vue → Nuxt.js 3+
│ │ └─ Team flexible → Next.js (ecosystem advantage)
│ │
│ ├─ SPA without SSR requirements
│ │ ├─ React experience → React 18+ (Vite)
│ │ ├─ Vue experience → Vue 3 (Vite)
│ │ └─ Enterprise/complex forms → Angular 15+
│ │
│ └─ Static site (blog, docs)
│ └─ Astro, Next.js SSG, or Vite + React
│
└─ Existing Project
└─ Continue with existing framework (consistency)
| Scenario | Library | Bundle Size | Use Case |
|---|---|---|---|
| Simple local state | useState, useReducer | 0 KB | Component-level state |
| Shared state (2-3 components) | Context API | 0 KB | Theme, auth, simple global |
| Medium app (<10 slices) | Zustand | ~1 KB | Most apps, good DX |
| Large app (10+ slices) | Redux Toolkit | ~11 KB | Enterprise, time-travel debug |
| Server state | TanStack Query | ~12 KB | API data, caching |
Styling Decision
├─ Rapid prototyping → Tailwind CSS
├─ Component library → Radix UI + Tailwind
├─ Dynamic theming → CSS-in-JS (Styled Components, Emotion)
├─ Large team → CSS Modules or Tailwind + Design Tokens
└─ Performance-critical → Plain CSS / SCSS
function useFetch<T>(url: string) {
const [data, setData] = useState<T | null>(null);
const [loading, setLoading] = useState(true);
const [error, setError] = useState<string | null>(null);
useEffect(() => {
fetch(url)
.then(res => res.json())
.then(setData)
.catch(setError)
.finally(() => setLoading(false));
}, [url]);
return { data, loading, error };
}
// Presentational (dumb)
const UserList = ({ users, onUserClick }: UserListProps) => (
<ul>
{users.map(user => (
<li key={user.id} onClick={() => onUserClick(user.id)}>
{user.name}
</li>
))}
</ul>
);
// Container (smart)
const UserListContainer = () => {
const { users, fetchUsers } = useUsers();
useEffect(() => fetchUsers(), [fetchUsers]);
return <UserList users={users} onUserClick={handleClick} />;
};
State not updating
Component not re-rendering
Performance issues
Tests failing
Weekly Installs
121
Repository
GitHub Stars
43
First Seen
Jan 24, 2026
Security Audits
Gen Agent Trust HubFailSocketPassSnykPass
Installed on
opencode98
codex93
gemini-cli90
cursor85
github-copilot81
claude-code81
Flutter应用架构设计指南:分层结构、数据层实现与最佳实践
4,100 周安装