agentleFS
blackbenjaminblackbenjamin/etps/.claude/skills/nextjs-frontend/SKILL.md

nextjs-frontend

Skill1 starsChanged 11 months agoMITView on GitHub

Build Next.js pages with shadcn/ui components, React hooks, TypeScript, and TanStack Query. Use when working on frontend/ directory, UI components, pages, hooks, or API integration.

  • Reads credentials

4 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 4 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 3 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use shadcn/ui for all UI components

    line 81
  2. Distinctive:

    Use TanStack Query for API calls (caching, loading states)

    line 83
  3. Distinctive:

    Keep components focused and composable

    line 84
  4. Distinctive:

    Use 'use client' directive for interactive components

    line 85

“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Next.js Frontend for ETPS

Tech Stack

  • Framework: Next.js 14 (App Router)
  • UI: shadcn/ui components
  • Styling: Tailwind CSS
  • State: TanStack Query for API caching
  • Language: TypeScript

Key Directories

frontend/src/
├── app/           # Pages and layouts
├── components/    # React components
│   ├── ui/        # shadcn/ui components
│   ├── generation/# Resume/CL generation UI
│   └── job-intake/# Job intake form
├── hooks/         # Custom hooks (queries.ts)
├── lib/           # Utilities (api.ts, utils.ts)
└── types/         # TypeScript types

API Integration

// frontend/src/lib/api.ts
const API_BASE = process.env.NEXT_PUBLIC_API_URL || 'http://localhost:8000'

export const api = {
  parseJobDescription: (data: JobParseRequest) =>
    apiFetch<JobProfile>('/api/v1/job/parse', {
      method: 'POST',
      body: JSON.stringify(data),
    }),
  // ...
}

React Query Hooks

// frontend/src/hooks/queries.ts
export function useParseJobDescription() {
  return useMutation({
    mutationFn: (data: JobParseRequest) => api.parseJobDescription(data),
  })
}

Component Pattern

'use client'

import { Button } from '@/components/ui/button'
import { Card } from '@/components/ui/card'

interface MyComponentProps {
  data: SomeType
}

export function MyComponent({ data }: MyComponentProps) {
  return (
    <Card>
      <Button>Action</Button>
    </Card>
  )
}

Environment Variables

  • NEXT_PUBLIC_API_URL - Backend API URL
  • NEXT_PUBLIC_USER_NAME - User's name for documents
  • NEXT_PUBLIC_USER_EMAIL - User's email for documents
  • NEXT_PUBLIC_USER_PHONE - User's phone for documents
  • NEXT_PUBLIC_USER_LINKEDIN - User's LinkedIn URL

Best Practices

  1. Use shadcn/ui for all UI components
  2. Type all props with TypeScript interfaces
  3. Use TanStack Query for API calls (caching, loading states)
  4. Keep components focused and composable
  5. Use 'use client' directive for interactive components

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.