Token导航 LogoToken导航TokenDH.com
研究检索需要联网github未标认证来源可访问许可证需确认审计通过

frontendfrontend 开发

Agent Skill

用于辅助前端页面、组件、样式和交互逻辑的开发与维护。它适合让 Agent 生成或审查 React、Next.js、Vue、Tailwind、CSS 等相关代码,整理组件结构,或定位布局和性能问题。使用时需要结合项目现有设计系统、路由和构建方式,避免只生成孤立片段;涉及页面改动时,应配合本地预览和构建检查确认视觉效果。

总安装

259

周安装

11

GitHub Stars

3

下载量

91
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:frontend(frontend 开发)
来源仓库:https://github.com/dedalus-erp-pas/foundation-skills
仓库路径:skills/frontend
安装命令:
npx skills add https://github.com/dedalus-erp-pas/foundation-skills --skill frontend
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/dedalus-erp-pas/foundation-skills --skill frontend

简介

frontend 辅助 React、Next.js、Vue、Tailwind 等前端代码的开发与维护,定位布局和性能问题。

  • 强调使用框架原生方式,避免对抗式设计,确保组件结构与路由系统集成。
  • 适用于生成页面片段、审查样式逻辑或优化加载性能,但不替代完整应用搭建。
  • 涉及页面改动时应配合本地预览和构建检查,避免孤立代码片段造成渲染异常。
  • frontend 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

Frontend Design Skill

This skill enforces a single principle: work WITH the framework, never against it. Use the component library natively. Use the CSS framework idiomatically. Let the design system do its job.

The user provides frontend requirements: a component, page, or interface to build or modify.

Core Philosophy

Don't fight the framework. Use it as it was designed to be used.

Every frontend framework and component library has an intended way to be used. The job of this skill is to ensure that every line of frontend code respects that intent. Customization happens through the channels the framework provides — not by bypassing them.

Step 1: Codebase Context Discovery (MANDATORY)

Before writing any code, scan the codebase. This step is non-negotiable.

What to Detect

  1. Frontend framework — Check package.json for: react, vue, angular, svelte, next, nuxt, astro, solid-js
  2. Component library — Check dependencies for: PrimeVue, shadcn/ui, Vuetify, MUI, Chakra UI, Ant Design, Radix, Mantine, Quasar, Element Plus, Headless UI
  3. CSS framework — Check for: Tailwind (tailwind.config.*, @tailwind directives), SCSS, CSS Modules, etc.
  4. Theme configuration — Find the theming mechanism:

- PrimeVue: theme preset in main.ts (Aura, Lara, Nora), design token overrides - Vuetify: vuetify.ts theme config - MUI: createTheme() config - Tailwind: tailwind.config.* or @theme block (v4)

  1. Existing component patterns — Examine 2-3 existing components to understand how the library is used in practice

State your findings before proceeding. Example: "Detected: Vue 3 + PrimeVue (Aura preset) + Tailwind CSS. I will use PrimeVue components natively with Tailwind for layout only."

Step 2: Framework-Native Implementation

The Golden Rule

Use every component, utility, and API the way the framework documentation shows it. If the framework has a built-in way to do something, use it. Do not invent alternatives.

Component Library Rules

These rules apply regardless of which component library the project uses (PrimeVue, MUI, Vuetify, shadcn/ui, etc.):

ALWAYS:

  • Use the library's components directly with their documented props and API
  • Customize appearance through the library's theming system (design tokens, theme presets, theme config)
  • Use the library's built-in variants, severities, and sizes (severity="success", size="small", etc.)
  • Use the library's slot system when you need to customize content areas
  • Follow the library's documented patterns for forms, dialogs, tables, etc.
  • Use the library's icons and icon integration as documented

NEVER:

  • Override component internals with CSS targeting internal class names or DOM structure
  • Create wrapper components that re-style library components from the outside
  • Use !important to override library styles
  • Duplicate functionality that already exists in the library (if it has a Tooltip, use it)
  • Mix components from multiple UI libraries in the same project

PrimeVue-Specific Rules

PrimeVue v4 uses a design token system with presets (Aura, Lara, Nora). This is the ONLY supported customization path.

NEVER do this:

  • Use the PassThrough (pt) API to restyle components with Tailwind classes
  • Use unstyled mode to strip PrimeVue's styles and rebuild from scratch
  • Use usePassThrough() utility to override preset styling
  • Create wrapper components that apply pt overrides globally
  • Target PrimeVue's internal CSS classes (.p-button-label, .p-datatable-header, etc.) in your stylesheets
  • Add Tailwind utility classes to PrimeVue component root elements to override their appearance

DO this instead:

  • Pick a theme preset (Aura, Lara, Nora) and use it
  • Customize through PrimeVue's design token system in main.ts or theme config: app.use(PrimeVue, {theme: {preset: Aura, options: {prefix: 'p', darkModeSelector: '.dark-mode', cssLayer: {name: 'primevue', order: 'tailwind-base, primevue, tailwind-utilities'}}}})
  • Override design tokens at the theme level when you need different colors or spacing: import {definePreset} from '@primevue/themes' import Aura from '@primevue/themes/aura' const MyPreset = definePreset(Aura, {semantic: {primary: {50: '{indigo.50}', //... 950: '{indigo.950}'}}})
  • Use component props as documented: severity, size, outlined, rounded, raised, text, etc.
  • Use PrimeVue's built-in CSS layer ordering to ensure Tailwind and PrimeVue coexist cleanly

Why no pt? The PassThrough API fights the framework. It bypasses the theming system, creates maintenance burden when PrimeVue updates internal DOM structure, and produces code that is neither idiomatic PrimeVue nor idiomatic Tailwind. The design token system exists precisely so you don't need pt.

CSS Framework Rules (Tailwind)

When the project uses Tailwind CSS, follow these rules on every frontend change:

ALWAYS:

  • Use Tailwind utility classes directly in templates — this is the primary styling mechanism
  • Follow mobile-first responsive design: base styles first, then sm:, md:, lg:, xl:
  • Use consistent class ordering: layout > positioning > box model > typography > visual > interactive
  • Use the project's Tailwind config tokens (text-primary-500, not text-[#3b82f6])
  • Use complete class strings — never concatenate (bg-${color}-500 breaks the compiler)
  • Use computed properties or lookup objects for dynamic classes
  • Use prettier-plugin-tailwindcss for automatic class sorting if available
  • Use Tailwind for layout, spacing, and typography on YOUR elements (not library components)

NEVER:

  • Write custom CSS when a Tailwind utility exists for it
  • Use @apply excessively — prefer Vue components for abstraction instead of CSS classes
  • Use arbitrary values (text-[14px]) when a Tailwind scale value exists (text-sm)
  • Concatenate class names dynamically (breaks purging in production)
  • Mix CSS methodologies — if the project uses Tailwind, don't add CSS Modules or styled-components
  • Use Tailwind utilities to override component library styles

Tailwind + Component Library coexistence:

  • Tailwind handles: page layout, spacing between components, custom elements, typography on non-library elements
  • Component library handles: component appearance, component spacing internals, interactive states
  • They do NOT overlap: don't use Tailwind to restyle library components, don't use library classes for page layout

Tailwind Best Practices Checklist

Apply this checklist on every frontend change:

  • Mobile-first: base styles are mobile, breakpoints add complexity
  • No arbitrary values when a scale value exists
  • No @apply — use Vue components for repeated patterns
  • No class concatenation — use lookup objects for dynamic classes
  • Consistent class ordering (use Prettier plugin)
  • Dark mode uses dark: prefix consistently
  • Interactive states use hover:, focus:, active:, disabled: variants
  • Focus styles are visible for accessibility (focus:ring-2, focus:outline-none)
  • Design tokens from tailwind.config are used, not hardcoded values
  • No conflicting utilities on the same element

Step 3: What This Skill is NOT

This skill does NOT cover:

  • Aesthetic direction or creative design — it enforces framework discipline, not visual creativity
  • Framework-specific API patterns — defer to vue-best-practices, react-best-practices for those
  • Greenfield design system creation — use create-design-system-rules for that

What to AVOID — Summary

Anti-patternWhy it's wrongWhat to do instead
pt API on PrimeVue componentsFights the framework's theming systemUse design tokens and definePreset()
unstyled mode + Tailwind rebuildRe-implements PrimeVue from scratchUse a theme preset
Wrapper components with style overridesUnnecessary abstraction, breaks on updatesUse components directly with props
!important overridesSpecificity wars, unmaintainableFix the root cause through theme config
Tailwind classes on library componentsTwo systems fighting for controlLet the library own its components
Custom CSS for things Tailwind doesMixed methodologiesUse Tailwind utilities
@apply everywhereDefeats utility-first purposeExtract Vue components instead
Arbitrary values (text-[14px])Bypasses design token systemUse scale values (text-sm)
Class concatenation (bg-${x}-500)Breaks Tailwind compiler purgingUse lookup objects
Targeting internal library classesBreaks on library updatesUse library's theming API

Complementary Skills

  • vue-best-practices / react-best-practices — Framework-specific API patterns and component architecture
  • create-design-system-rules — For projects without an established design system
  • web-design-guidelines — For auditing accessibility and UI quality

Remember

The best frontend code is invisible. It uses the tools the project chose — the component library, the CSS framework, the theme system — exactly as they were meant to be used. No overrides. No workarounds. No cleverness that the next developer has to reverse-engineer.

Use the framework. Trust the framework. Don't fight the framework.

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

34.34%
按下载量换算31

Claude

29.62%
按下载量换算27

Cursor

19.98%
按下载量换算18

Gemini CLI

10.5%
按下载量换算10

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills