modern-web-development — Claude Code skill: Next.js and TypeScript
A rule set for the modern web stack: TypeScript, Next.js 14, React Server Components, Supabase, GraphQL and Tailwind CSS. Useful when your agent writes frontend and API code in the same repo.
npx skills add Mindrally/skills --skill modern-web-development -a claude-codeWhat modern-web-development does
The skill feeds your agent a code standard. Inside are style requirements: functional and declarative code over classes, the function keyword for pure functions, interfaces instead of types, variable names with auxiliary verbs like isLoading, and the RORO pattern. Files are meant to be ordered as exported component, subcomponents, helpers, static content, types.
React and Next.js rules are specific. Keep use client, useEffect and setState to a minimum and lean on server components. Client components get wrapped in Suspense with a fallback, non-critical ones load dynamically, forms validate through Zod. For data, the skill points to server components and the preload pattern to avoid waterfalls, Supabase for real-time sync, Vercel KV for chat history and sessions. On the GraphQL side it suggests Genql for type safety.
Separate sections cover Supabase with Row Level Security policies, Auth, Storage and Edge Functions; Tailwind with Class Variance Authority for component variants; three levels of tests; and accessibility through keyboard navigation, ARIA and WCAG contrast. The style guide drops semicolons and puts early returns at function entry points. If your codebase is class-based or styles with something other than Tailwind, these rules will fight your existing code — worth checking before you enable the whole thing.
What it helps with
- hold one TypeScript style across the whole project
- move pages to React Server Components and cut stray
use client - wire data fetching through Supabase with RLS policies
- type GraphQL queries without hand-written interfaces
- keep component and helper files in a predictable order
Example prompts for the agent
- build a catalog page in Next.js 14 with a server component fetching from Supabase
- review this component against the skill rules and remove unnecessary
use clientanduseEffect - add a form with Zod validation and wrap the client part in Suspense
How to install modern-web-development
1Skills CLI (Vercel)
npx skills add Mindrally/skills --skill modern-web-development -a claude-code2Manually: put the files in place
~/.claude/skills/modern-web-development/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/modern-web-development/
1Skills CLI (Vercel)
npx skills add Mindrally/skills --skill modern-web-development -a codex2Manually: put the files in place
.agents/skills/modern-web-development/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add Mindrally/skills --skill modern-web-development -a cursor2Manually: put the files in place
.cursor/skills/modern-web-development/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install Mindrally/skills modern-web-development2Manually: put the files in place
.github/skills/modern-web-development/SKILL.md1Skills CLI (Vercel)
npx skills add Mindrally/skills --skill modern-web-development -a gemini-cli2Platform CLI
gemini skills install https://github.com/Mindrally/skills --path modern-web-developmentManually: put the files in place
.devin/skills/modern-web-development/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add Mindrally/skills --skill modern-web-development -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about modern-web-development
How do I install modern-web-development in Claude?
Run npx skills add Mindrally/skills --skill modern-web-development -a claude-code. The skill lands in ~/.claude/skills/modern-web-development/SKILL.md.
What does modern-web-development do?
It gives the agent a set of rules for the modern web stack: TypeScript, Next.js 14, React Server Components, Supabase, GraphQL and Tailwind CSS. The agent follows them while writing or editing code.
Which platforms support the skill?
Besides Claude, there are install paths for Codex, Cursor, GitHub Copilot, Gemini CLI and OpenCode. GitHub Copilot uses a different command: gh skill install Mindrally/skills modern-web-development.
Source text
SKILL.md · Apache-2.0
--- name: modern-web-development description: Modern web development best practices for TypeScript, Next.js 14, React Server Components, Supabase, GraphQL, and Tailwind CSS. metadata: maintainer: Mindrally source: https://github.com/Mindrally/skills --- # Modern Web Development Brandon Fernandez's comprehensive cursor rules for modern web development with TypeScript, Node.js, Next.js 14, React, Supabase, GraphQL, Tailwind CSS, Radix UI, and Shadcn UI. ## Key Development Principles ### Code Style and Architecture - Write concise, technical responses with accurate TypeScript examples - Employ functional, declarative programming while avoiding class-based approaches - Prioritize iteration and modularization over code duplication - Use descriptive variable names with auxiliary verbs (`isLoading`, `hasError`) - Implement the RORO pattern (Receive an Object, Return an Object) ### JavaScript/TypeScript Standards - Use `function` keyword for pure functions - Omit semicolons - Leverage TypeScript exclusively, preferring interfaces over types - Structure files as: exported component, subcomponents, helpers, static content, types - Minimize unnecessary curly braces in conditionals ### Error Handling - Address errors and edge cases at function entry points - Apply early returns for error conditions avoiding deep nesting - Position the success path last for improved readability - Use guard clauses for precondition validation - Implement user-friendly error messaging ## React and Next.js Guidelines - Use functional components with TypeScript interfaces - Write declarative JSX using `function` declarations - Style with Shadcn UI, Radix, and Tailwind CSS - Implement mobile-first responsive design - Minimize `use client`, `useEffect`, and `setState` - favor React Server Components - Employ Zod for form validation - Wrap client components in Suspense with fallbacks - Use dynamic loading for non-critical components - Optimize images (WebP format, size data, lazy loading) ## Data and State Management - Leverage React Server Components for data fetching - Implement the preload pattern to prevent waterfalls - Use Supabase for real-time synchronization and state management - Consider Vercel KV for chat history, rate limiting, and sessions ## Supabase and GraphQL - Use Supabase client for database interactions and subscriptions - Implement Row Level Security (RLS) policies - Leverage Supabase Auth, Storage, and Edge Functions - Use Genql for type-safe GraphQL API interactions - Optimize GraphQL queries to fetch only necessary data ## Styling and Testing ### Styling - Apply Tailwind CSS utility-first approach - Use Class Variance Authority (CVA) for component variants ### Testing - Implement unit tests for utilities and hooks - Create integration tests for complex components - Develop end-to-end tests for critical user flows ## Accessibility and Documentation ### Accessibility - Ensure keyboard navigation throughout interfaces - Implement proper ARIA labels and semantic roles - Maintain WCAG-compliant color contrast ratios ### Documentation - Provide clear JSDoc comments for IDE intellisense - Document Supabase schemas, RLS policies, and Edge Functions
© Mindrally · Apache-2.0 · Mindrally/skills