Skip to content

borghei/Claude-Skills / engineering/senior-frontend

senior-frontend

Verified

Scaffold Next.js 16 or React + Vite 8 apps, generate components with tests and stories, and flag heavy bundle dependencies. Use when starting a React project, adding components or hooks, or reviewing frontend code or performance.

FileKindSize
SKILL.mdskill md12.2 KB
assets/sample-project-flawed/package.jsonmanifest413 B
assets/sample-project-flawed/src/App.tsxother268 B
assets/sample-project-sound/app/page.tsxother131 B
assets/sample-project-sound/next.config.jsscript255 B
assets/sample-project-sound/package.jsonmanifest476 B
assets/templates/component/client.tsx.tmplother297 B
assets/templates/component/hook.ts.tmplother826 B
assets/templates/component/index.ts.tmplother84 B
assets/templates/component/index_hook.ts.tmplother115 B
assets/templates/component/server.tsx.tmplother447 B
assets/templates/component/story.tsx.tmplother601 B
assets/templates/component/test.tsx.tmplother538 B
assets/templates/scaffold/config/eslint.config.mjs.tmplother190 B
assets/templates/scaffold/config/gitignore.tmplother246 B
assets/templates/scaffold/config/next.config.js.tmplother248 B
assets/templates/scaffold/config/postcss.config.js.tmplother151 B
assets/templates/scaffold/config/prettierrc.tmplother106 B
assets/templates/scaffold/config/tailwind.config.ts.tmplother1.3 KB
assets/templates/scaffold/config/tsconfig.json.tmplother572 B
assets/templates/scaffold/config/vite/eslint.config.js.tmplother361 B
assets/templates/scaffold/config/vite/index.html.tmplother303 B
assets/templates/scaffold/config/vite/postcss.config.js.tmplother149 B
assets/templates/scaffold/config/vite/tsconfig.app.json.tmplother649 B
assets/templates/scaffold/config/vite/tsconfig.json.tmplother119 B
assets/templates/scaffold/config/vite/tsconfig.node.json.tmplother557 B
assets/templates/scaffold/config/vite/vite.config.ts.tmplother282 B
assets/templates/scaffold/files/api_client.tsscript2.1 KB
assets/templates/scaffold/files/auth_client.tsscript1.3 KB
assets/templates/scaffold/files/auth_lib.tsscript2.7 KB
assets/templates/scaffold/files/auth_page.tsxother281 B
assets/templates/scaffold/files/auth_proxy.tsscript525 B
assets/templates/scaffold/files/constants.tsscript327 B
assets/templates/scaffold/files/empty.txtmarkdown0 B
assets/templates/scaffold/files/form_field.tsxother1.7 KB
assets/templates/scaffold/files/form_utils.tsscript762 B
assets/templates/scaffold/files/globals_css.cssother856 B
assets/templates/scaffold/files/health_route.tsscript171 B
assets/templates/scaffold/files/home_page.tsxother304 B
assets/templates/scaffold/files/hook_debounce.tsscript357 B
assets/templates/scaffold/files/hook_local_storage.tsscript659 B
assets/templates/scaffold/files/layout_footer.tsxother265 B
assets/templates/scaffold/files/layout_header.tsxother518 B
assets/templates/scaffold/files/layout_sidebar.tsxother287 B
assets/templates/scaffold/files/login_form.tsxother2.2 KB
assets/templates/scaffold/files/query_client.tsscript662 B
assets/templates/scaffold/files/query_provider.tsxother353 B
assets/templates/scaffold/files/react_app.tsxother403 B
assets/templates/scaffold/files/react_main.tsxother236 B
assets/templates/scaffold/files/register_form.tsxother3.2 KB
assets/templates/scaffold/files/require_auth.tsxother821 B
assets/templates/scaffold/files/root_layout.tsxother512 B
assets/templates/scaffold/files/storybook_main_next.tsscript302 B
assets/templates/scaffold/files/storybook_main_react.tsscript231 B
assets/templates/scaffold/files/storybook_preview_next.tsscript264 B
assets/templates/scaffold/files/storybook_preview_react.tsscript261 B
assets/templates/scaffold/files/test_setup.tsscript244 B
assets/templates/scaffold/files/test_utils.tsxother541 B
assets/templates/scaffold/files/types_index.tsscript309 B
assets/templates/scaffold/files/ui_button.tsxother1.4 KB
assets/templates/scaffold/files/ui_card.tsxother984 B
assets/templates/scaffold/files/ui_index.tsscript147 B
assets/templates/scaffold/files/ui_input.tsxother1.1 KB
assets/templates/scaffold/files/utils.tsscript478 B
assets/templates/scaffold/files/vitest_config_next.tsscript438 B
assets/templates/scaffold/files/vitest_config_react.tsscript389 B
assets/templates/scaffold/manifest.jsonconfig12.6 KB
references/bundle_rules.jsonconfig3.4 KB
references/code-patterns.mdmarkdown5.7 KB
references/frontend_best_practices.mdmarkdown19.4 KB
references/nextjs_optimization_guide.mdmarkdown17.3 KB
references/react_patterns.mdmarkdown16.9 KB
references/tooling-guide.mdmarkdown15.1 KB
scripts/bundle_analyzer.pyexecutablescript11.6 KB
scripts/component_generator.pyexecutablescript8.5 KB
scripts/frontend_scaffolder.pyexecutablescript11.0 KB

references/bundle_rules.json

View on GitHub
{
  "_comment": "Rule tables for scripts/bundle_analyzer.py. Sizes are rough minified figures.",
  "heavy_packages": {
    "moment": {
      "size": "290KB",
      "alternative": "date-fns (12KB) or dayjs (2KB)",
      "reason": "Large locale files bundled by default"
    },
    "lodash": {
      "size": "71KB",
      "alternative": "lodash-es with tree-shaking or individual imports (lodash/get)",
      "reason": "Full library often imported when only few functions needed"
    },
    "jquery": {
      "size": "87KB",
      "alternative": "Native DOM APIs or React/Vue patterns",
      "reason": "Rarely needed in modern frameworks"
    },
    "axios": {
      "size": "14KB",
      "alternative": "Native fetch API (0KB) or ky (3KB)",
      "reason": "Fetch API covers most use cases"
    },
    "underscore": {
      "size": "17KB",
      "alternative": "Native ES6+ methods or lodash-es",
      "reason": "Most utilities now in standard JavaScript"
    },
    "chart.js": {
      "size": "180KB",
      "alternative": "recharts (bundled with React) or lightweight-charts",
      "reason": "Consider if you need all chart types"
    },
    "three": {
      "size": "600KB",
      "alternative": "None - use dynamic import for 3D features",
      "reason": "Very large, should be lazy-loaded"
    },
    "firebase": {
      "size": "400KB+",
      "alternative": "Import specific modules (firebase/auth, firebase/firestore)",
      "reason": "Modular imports significantly reduce size"
    },
    "material-ui": {
      "size": "Large",
      "alternative": "shadcn/ui (copy-paste components) or Tailwind",
      "reason": "Heavy runtime, consider headless alternatives"
    },
    "@mui/material": {
      "size": "Large",
      "alternative": "shadcn/ui or Radix UI + Tailwind",
      "reason": "Heavy runtime, consider headless alternatives"
    },
    "antd": {
      "size": "Large",
      "alternative": "shadcn/ui or Radix UI + Tailwind",
      "reason": "Heavy runtime, consider headless alternatives"
    }
  },
  "package_optimizations": {
    "react-icons": "Import individual icons: import { FaHome } from 'react-icons/fa'",
    "date-fns": "Use tree-shaking: import { format } from 'date-fns'",
    "@heroicons/react": "Already tree-shakeable, good choice",
    "lucide-react": "Already tree-shakeable, add to optimizePackageImports in next.config.js",
    "framer-motion": "Use dynamic import for non-critical animations",
    "recharts": "Consider lazy loading for dashboard charts"
  },
  "dev_only_packages": [
    "typescript",
    "@types/",
    "eslint",
    "prettier",
    "jest",
    "vitest",
    "@testing-library",
    "cypress",
    "playwright",
    "storybook",
    "@storybook",
    "webpack",
    "vite",
    "rollup",
    "esbuild",
    "tailwindcss",
    "postcss",
    "autoprefixer",
    "sass",
    "less",
    "husky",
    "lint-staged"
  ],
  "state_libs": [
    "redux",
    "@reduxjs/toolkit",
    "mobx",
    "zustand",
    "jotai",
    "recoil",
    "valtio"
  ],
  "import_patterns": [
    [
      "import\\s+\\*\\s+as\\s+\\w+\\s+from\\s+['\\\"]lodash['\\\"]",
      "Avoid import * from lodash, use individual imports"
    ],
    [
      "import\\s+moment\\s+from\\s+['\\\"]moment['\\\"]",
      "Consider replacing moment with date-fns or dayjs"
    ],
    [
      "import\\s+\\{\\s*\\w+(?:,\\s*\\w+){5,}\\s*\\}\\s+from\\s+['\\\"]react-icons",
      "Import icons from specific icon sets (react-icons/fa)"
    ]
  ]
}
finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the workStars: 322kUpdated Claude CodeCodexVerifiedInstall
systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixesStars: 322kUpdated Claude CodeCodexVerifiedInstall
test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation codeStars: 322kUpdated Claude CodeCodexVerifiedInstall
skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy.Stars: 198kUpdated Claude CodeCodexVerifiedInstall