Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add ApexIQ/skillsmith --skill frontend_best_practicesgit clone --depth 1 https://github.com/ApexIQ/skillsmithWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/apexiq/skillsmith/frontend_best_practices)<a href="https://agentmods.dev/skills/apexiq/skillsmith/frontend_best_practices"><img src="https://agentmods.dev/badge/skills/apexiq/skillsmith/frontend_best_practices/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/apexiq/skillsmith/frontend_best_practices"><img src="https://agentmods.dev/badge/skills/apexiq/skillsmith/frontend_best_practices.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00029 | $0.00542 |
| Opus 5.5 | $0.00012 | $0.00217 |
| Sonnet 5.5 | $0.00006 | $0.00108 |
| Haiku 4.5 | $0.00003 | $0.00054 |
Grade A, and why
frontend-best-practices scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
⚛️ Frontend Best Practices
1. Premium UX Principles
| Principle | Implementation | Example |
|---|---|---|
| Optimistic UI | Mutate state instantly, sync with server later. Revert on error. | Delete item -> Remove from list immediately -> Call API. |
| Physics-Based Motion | Use animation libraries with spring physics. No linear eases. | framer-motion with type: "spring". |
| Keyboard First | Every action has a hotkey. Command palette for power users. | Global Cmd+K for navigation/actions. |
2. React Architecture
- Hooks: Logic lives in custom hooks (
useAuth,useApi), not in components. - Context: Use for global state (User, Theme). Avoid props drilling.
- Components: Small, single-responsibility. Shared UI in
components/ui/.
3. Styling (Tailwind or CSS-in-JS)
- Utility First: Prefer utility classes over custom CSS.
- Conditional Styles: Use a utility like
clsxorcn()for conditionals.<div className={cn("p-4", isActive && "bg-primary")} /> - Design Tokens: Use semantic colors (
bg-background,text-foreground) for dark mode.
4. Data Fetching
- SWR / TanStack Query: Never use raw
useEffectfor API calls. - Stale-While-Revalidate: Show cached data while fetching fresh data.
5. Project Structure
src/
features/ # Domain logic (Auth, Dashboard)
components/ # Shared UI (Button, Modal)
hooks/ # Custom hooks (useAuth, useKeyboard)
lib/ # Utilities (API client, formatters)
pages/ # Route components
Examples
- New component: Create in
components/ui/-> Use utility classes -> Export from index.
Guidelines
- Test with testing-library (see
frontend_testingskill). - Accessibility first: use semantic HTML and ARIA attributes.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 58 lines · 29 tokens per session scan A edc59ac950c0
frontend-best-practices is a skill published in the GitHub repository ApexIQ/skillsmith (5 stars, last pushed 7mo ago), licensed MIT. It adds 29 tokens to every session and 542 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
shadcn
Manages shadcn components and projects — adding, searching, fixing, debugging, styling, and composing UI, including chat interfaces. Provides project context, component docs, and usage examples. Applies when working with shadcn/ui, component registries, presets, --preset codes, or any project with a components.json…
design
Use when designing, redesigning, restyling or reviewing a web page or app screen (landing, product site, portfolio, dashboard, docs) or when a UI looks generic or AI-made. Deals a researched direction, takes the idea from the subject, uses real pictures, proves it in a browser. NOT the words (landing-copy), NOT…
frontend-design
Create distinctive, production-grade Stellar dApp UI. Combines bold aesthetic direction with smart contract integration patterns — wallet connection flows, transaction UX, contract data displays, and agentic kit hook wiring. No generic "AI slop" aesthetics.
frontend-ui-design
Use when design and build production-grade UI components using React, Vue, or vanilla HTML/CSS. Create responsive layouts, design systems, and accessible interfaces. Use when designing and build production-grade ui components using react, vue, or.
dev-shadcn
Integration and customization of shadcn/ui (copy-paste React components, Radix + Tailwind). Trigger when the user wants to install shadcn, add components, customize the theme, or when shadcn/ui usage is detected in the project.
design-system
Document and define UI design system tokens, components, and guidelines.