Към всички skills

frontend-module-standards

siteboon · Тестване

Enforce this repository's React and TypeScript frontend module architecture standards. Use whenever creating, modifying, refactoring, or reviewing frontend code under `src/`, including feature modules, components, hooks, contexts, shared UI, API access, state, utilities, and frontend tests. Do not apply these rules to backend code under `server/` or non-frontend scaffolding.

Оригинален текст · няма потвърден превод на български

Теми: anthropic · anthropic-ai · anthropic-claude · claude · claude-api · claude-code · claude-code-ui · claudecode · gui · mobile-first · react · ui

Първо прочетете инструкцията.

Файлът се зарежда от посочения източник само по ваше действие. Можете да го прочетете тук, да го копирате или да го запазите като .md.

Оригинален SKILL.md
GitHub хранилище
Звезди на репото
13 785
Лиценз
AGPL-3.0
Последна проверка на записа
20.09.2026 г.

Добавете в своя инструмент.

Командата отваря избора на skills от репозитория. Прочетете файла и условията на автора преди изпълнение.

npx skills add siteboon/claudecodeui

Страницата копира текст. Не инсталира и не изпълнява нищо на устройството ви.

Откъс от SKILL.md

Началото на файла на автора, без превод.

Frontend Module Standards

Apply these rules only to frontend code under src/. Preserve the requested task scope: make touched and newly generated frontend code compliant without performing an unrelated repository-wide migration.

Inspect before editing

  1. Identify the owning feature module and its existing barrel, components, hooks, contexts, utilities, state, API usage, and tests.
  2. Search for existing shared types, utilities, constants, UI components, hooks, and contexts before adding a new definition.
  3. Search for every consumer before moving a definition or changing a module's public exports.
  4. Distinguish application-source imports from package imports before applying the @ alias rules.

Use source-root imports

  • Treat @ as the alias for src.
  • Use @/... imports whenever the import target is frontend application code inside src, including imports within the same feature module.
  • Do not use relative paths such as ../, ../../, or ./ for application-source imports.
  • Continue using bare package specifiers for external dependencies, such as react or react-router-dom.
  • Use import type for every type-only import.

Organize feature modules

  • Place every frontend feature in src/modules/<feature>/.
  • Use .ts for non-JSX files and .tsx for files containing JSX. Do not add JavaScript feature-module files.
  • Give every feature module an index.ts barrel that exposes only its required public API.
  • Import another feature module only through that module's index.ts. Never deep-import another module's components, hooks, contexts, modals, utilities, or other implementation details.
  • Keep module-private implementation details out of the barrel.
  • Do not create view/ directories inside feature modules.
  • Keep module-owned UI components within the owning module, either at its root or in clearly named component-specific directories.

A feature module may contain only the directories it needs:

src/modules/<feature>/
|-- index.ts
|-- FeatureComponent.tsx
|-- hooks/
|-- context/
|-- modals/
|-- utils/
`-- tests/

Design exports deliberately

Целият SKILL.md в GitHub