Skip to content

avibebuilder/claude-prime / .claude/starter-skills/frontend-development

frontend-development

Verified

Use this skill for ANY work involving React, Next.js, TypeScript, or Tailwind in the browser layer. This includes building components and pages, but equally covers debugging and fixing frontend issues: CSS/Tailwind classes not applying, form validation behavior, hydration mismatches between server and client renders, styling bugs, layout shifts, and rendering problems. Also use for refactoring components (e.g., splitting Server vs Client Components), data fetching patterns, state management, bundle optimization, and frontend tooling. If the problem involves what users see or interact with in a web browser — whether building, fixing, or refactoring — use this skill. Not for backend APIs, databases, infrastructure, or DevOps.

references/biome.md

View on GitHub
# BiomeJS Configuration

Fast, unified linter and formatter replacing ESLint + Prettier.

## Why Biome

- **Speed**: 10-100x faster than ESLint/Prettier
- **Unified**: Single tool for formatting + linting + import sorting
- **Zero config**: Sensible defaults, minimal setup

## Configuration

### biome.json

```json
{
  "$schema": "https://biomejs.dev/schemas/2.0.5/schema.json",
  "root": true,

  "files": {
    "includes": [
      "**/*.ts",
      "**/*.tsx",
      "**/*.js",
      "**/*.jsx",
      "**/*.json",
      "**/*.css",
      "!!.claude",
      "!!plans"
    ]
  },

  "vcs": {
    "enabled": true,
    "clientKind": "git",
    "useIgnoreFile": true
  },

  "formatter": {
    "enabled": true,
    "indentStyle": "space",
    "indentWidth": 2,
    "lineWidth": 100,
    "lineEnding": "lf"
  },

  "linter": {
    "enabled": true,
    "rules": {
      "recommended": true,
      "a11y": {
        "useSemanticElements": "off",
        "useKeyWithClickEvents": "off"
      },
      "correctness": {
        "noUnusedImports": {
          "level": "error",
          "fix": "safe"
        }
      },
      "nursery": {
        "useSortedClasses": {
          "level": "warn",
          "fix": "safe",
          "options": {
            "functions": ["cn", "clsx", "cva", "tw"]
          }
        }
      }
    }
  },

  "assist": {
    "enabled": true,
    "actions": {
      "source": {
        "organizeImports": {
          "level": "on",
          "options": {
            "groups": [
              ":NODE:",
              ":PACKAGE:",
              ":BLANK_LINE:",
              ":ALIAS:",
              ":BLANK_LINE:",
              ":PATH:"
            ]
          }
        }
      }
    }
  },

  "javascript": {
    "formatter": {
      "quoteStyle": "single",
      "jsxQuoteStyle": "double",
      "trailingCommas": "all",
      "semicolons": "always",
      "arrowParentheses": "always"
    }
  },

  "json": {
    "parser": {
      "allowComments": true,
      "allowTrailingCommas": true
    }
  },

  "css": {
    "formatter": { "enabled": true }
  },

  "overrides": [
    {
      "includes": ["*.config.js", "*.config.ts"],
      "linter": {
        "rules": {
          "style": { "noDefaultExport": "off" }
        }
      }
    }
  ]
}
```

### VSCode Settings

`.vscode/settings.json`:

```json
{
  "editor.defaultFormatter": "biomejs.biome",
  "editor.formatOnSave": true,
  "editor.codeActionsOnSave": {
    "source.addMissingImports": "always",
    "source.organizeImports.biome": "always",
    "source.fixAll.biome": "always"
  },
  "[javascript]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[javascriptreact]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[typescript]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[typescriptreact]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[json]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[jsonc]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "biome.enabled": true,
  "biome.requireConfiguration": true
}
```

## Key Features

### Tailwind Class Sorting

The `useSortedClasses` rule sorts Tailwind classes in:

- `className` and `class` attributes
- Utility functions: `cn()`, `clsx()`, `cva()`, tagged templates

Classes are sorted following Tailwind's recommended order (layout, flexbox, spacing, etc.).

> **Note:** The config uses `"fix": "safe"` to enable auto-fix on save. Default is `"unsafe"` which requires manual application.

### Import Ordering

Groups configured via `assist.actions.source.organizeImports`:

| Matcher        | Description                      |
| -------------- | -------------------------------- |
| `:NODE:`       | Node.js built-ins (`fs`, `path`) |
| `:PACKAGE:`    | npm packages                     |
| `:ALIAS:`      | Path aliases (`@/`, `~/`, `#`)   |
| `:PATH:`       | Relative imports (`./`, `../`)   |
| `:BLANK_LINE:` | Insert separator                 |

## Gotchas

| Issue                      | Reality                                         |
| -------------------------- | ----------------------------------------------- |
| `source.addMissingImports` | **VSCode/TypeScript feature**, not Biome        |
| Custom Tailwind config     | `useSortedClasses` ignores `tailwind.config.js` |
| Screen variants            | Not yet supported in class sorting              |
| Import organizing          | Use `biome check`, not `biome format`           |

## Advanced Setup

### Domains

Framework-specific rules auto-detected from `package.json`:

```json
"linter": {
  "domains": {
    "react": "recommended",
    "next": "recommended"
  }
}
```

Biome surfaces relevant rules (e.g., React Hooks, Next.js patterns) without manual configuration.

### Pre-commit Hooks

Native `--staged` support (v1.7+) eliminates need for lint-staged:

```bash
# .husky/pre-commit
npx biome check --staged --write
```

Setup: `npx husky init && echo 'npx biome check --staged --write' > .husky/pre-commit`

### CI/CD

```yaml
# .github/workflows/lint.yml
name: Lint
on: [push, pull_request]
jobs:
  lint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: biomejs/setup-biome@v2
      - run: biome ci .
```

The `biome ci` command exits non-zero on any issue (no auto-fix).

## CLI Commands

```bash
# All-in-one (format + lint + organize imports)
biome check --write .

# CI mode (check without writing)
biome check .

# Format only
biome format --write .

# Lint only
biome lint --write .
```
writing-skillsobra/superpowersUse when creating new skills, editing existing skills, or verifying skills work before deploymentStars: 322kUpdated Claude CodeCodexVerifiedInstall
xlsxanthropics/skillsUse this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .xltx, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like "the xlsx in my downloads") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved.Stars: 198kUpdated Claude CodeCodexVerifiedInstall
shipping-and-launchaddyosmani/agent-skillsPrepares production launches. Use when preparing to deploy to production, or when asking what needs to be in place before shipping. Use when you need a pre-launch checklist, when setting up monitoring, when planning a staged rollout, or when you need a rollback strategy.Stars: 119kUpdated Claude CodeCodexVerifiedInstall
childhoodthedotmack/claude-memBabysit a shipped release after merge, publication, or deployment. Verify published packages, production behavior, installed plugins, and late CI or user reports until the observation window is clean; use babysit for PR readiness before release.Stars: 118kUpdated Claude CodeCodexVerifiedInstall