project-structure-enforcer
Installation
SKILL.md
Contains Hooks
This skill uses Claude hooks which can execute code automatically in response to events. Review carefully before installing.
Enforce 2026 folder structure best practices with BLOCKING validation.
Validation Rules
BLOCKING Rules (exit 1)
| Rule | Check | Example Violation |
|---|---|---|
| Max Nesting | Max 4 levels from src/ or app/ | src/a/b/c/d/e/file.ts |
| No Barrel Files | No index.ts re-exports | src/components/index.ts |
| Component Location | React components in components/ or features/ | src/utils/Button.tsx |
| Hook Location | Custom hooks in hooks/ directory | src/components/useAuth.ts |
| Import Direction | Unidirectional: shared → features → app | features/ importing from app/ |