bootgs-architecture
Installation
SKILL.md
Bootgs Architecture
Available files
assets/eslint-boundaries.config.ts— a workingeslint-plugin-boundariesconfig enforcing every rule below. Copy it in and adjust thefilesglob to your source root. Theindex.ts-barrel rules are markedOPTIONAL— see Gotchas.
Layers and the one rule that matters
Dependencies point in one direction only: Controller → Service → Repository → Domain. bootgs's @RestController/@Injectable()/@Repository() decorators (see bootgs-quickstart) don't enforce this — there's no module system to scope it — so the rule has to be held either by review discipline or by the lint config below. Discipline erodes after a few PRs; the lint config doesn't.
| Layer | Contains | May import | Must not import |
|---|---|---|---|
| Domain | Entities (rich models with invariants), DTOs, enums, types, constants — pure TypeScript, no bootgs decorators | nothing above it | controller, service, repository, exceptions |
| Exceptions | Domain-specific Error subclasses |
domain | controller, service, repository |
| Repository | Data access via SpreadsheetApp/PropertiesService/CacheService, marked @Repository() |
domain, exceptions, shared | controller, service, another repository (one narrow exception — see Gotchas) |
| Service | Business logic, coordinates repositories, marked @Injectable() |
domain, exceptions, repository, shared | controller |
| Controller | @RestController classes — deserialize input, call services, format output |
domain, exceptions, service, shared | another controller, a repository directly |
| Shared | Cross-cutting utilities (guards, formatters) with no domain knowledge | nothing above it | controller, service, repository, domain, exceptions |