frontend-patterns
Skill by bybren-llc
Frontend patterns for Next.js App Router, Clerk auth, shadcn/Radix UI and PostHog analytics. It is meant for developers building UI components, pages, auth flows and analytics events in a project that uses these tools.
Install frontend-patterns
Built from the published package, never by AI.
git clone --depth 1 https://github.com/bybren-llc/safe-agentic-workflow /tmp/safe-agentic-workflow && mkdir -p ~/.claude/skills && cp -r /tmp/safe-agentic-workflow/.claude/skills/frontend-patterns ~/.claude/skills/frontend-patternsRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/bybren-llc/safe-agentic-workflow /tmp/safe-agentic-workflow && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/safe-agentic-workflow/.claude/skills/frontend-patterns ~/.gemini/antigravity-cli/skills/frontend-patternsAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Skills can run scripts on your machine. Some need an API key: check the README.
About
The frontend-patterns skill gives an AI assistant a set of coding conventions for a Next.js App Router project. It covers when to use server and client components, how to protect authenticated pages with force-dynamic and Clerk's auth helper, and how to check admin roles. It also includes shadcn/ui import paths, a React Hook Form and Zod form pattern, and button variants.
The skill also documents PostHog event naming in snake_case with a category prefix, event tracking, page view tracking and feature flags. An accessibility checklist and Tailwind responsive patterns are included, along with a list of common mistakes. The skill is marked as not user-invocable and is limited to Read, Grep and Glob tools. It is aimed at developers who want consistent UX and code patterns in a project that uses these tools.
Written from the project's SKILL.md and checked against it.
What it can do
- Server vs client componentsExplains when to use server components for data fetching and auth checks, and client components for interactivity.
- Protected pagesShows how to use force-dynamic and Clerk's auth to redirect signed-out users to sign-in.
- Admin verificationShows a pattern that checks the Clerk organization ID and role before rendering admin pages.
- Auth feature toggleDescribes a guest fallback when auth is disabled through a feature flag.
- Form patternProvides a React Hook Form and Zod form example using shadcn/ui form components.
- PostHog event namingLists snake_case event names grouped by user, feature, payment, content and navigation.
- PostHog trackingShows how to capture events, track page views and use feature flags with PostHog.
- Accessibility checklistLists keyboard, focus, contrast, alt text, ARIA label and error announcement checks.
- Responsive design patternsCovers mobile-first Tailwind breakpoints, container widths and show/hide classes.
What you need
- Next.js App Router project
- Clerk authentication
- shadcn/ui components
- PostHog analytics
Try asking
- Show me the pattern for a protected Next.js page that uses Clerk auth
- Create a form with React Hook Form and Zod using shadcn/ui components
- Which PostHog event name should I use for a checkout started action?
Good to know
- Provides patterns and guidance only, not runnable code generation tools
- Not user-invocable, so it is used by the assistant as background guidance
- Allowed tools are limited to Read, Grep and Glob
- References files such as patterns_library and config/features.ts that are not included in the source
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: .claude/skills/frontend-patterns/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
Allowed tools: ReadGrepGlob
Alternatives to frontend-patterns
All alternatives →Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.
Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.
Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.
Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.
Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.
Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.
Compare with openclaw-github-repo-commander, gradio or hig-components-menus
frontend-patterns: common questions
What does frontend-patterns do?
It gives an AI assistant conventions for Next.js App Router, Clerk auth, shadcn/ui and PostHog analytics. The source says it is meant to keep UI and analytics code consistent.
Does it require Clerk and PostHog?
The source describes patterns that use Clerk authentication and PostHog analytics. It assumes a project that already uses those tools.
Can the skill be invoked directly by users?
No. The source sets user-invocable to false, so it is applied as background guidance by the assistant.
How do I install frontend-patterns?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is frontend-patterns free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is frontend-patterns safe to use?
It scores 62 of 100. Grades: maintenance C, licence A, quality B. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to frontend-patterns?
Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.
