arch-audit

Detect architectural boundary and dependency violations across core, domain, and composition-root contexts.

15|7|Updated Sep 11, 2023
One-click install
npx skills add https://github.com/huseyindeniz/vite-react-dapp-template --skill arch-audit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: arch-audit
Source: https://github.com/huseyindeniz/vite-react-dapp-template/tree/main/.claude/skills/arch-audit
Command: npx skills add https://github.com/huseyindeniz/vite-react-dapp-template --skill arch-audit

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Enforce architectural boundaries and dependency rules across the codebase to ensure proper feature isolation and a stable composition root pattern.

Core Features & Use Cases

  • Architecture checks: Core → Domain dependencies, service imports, service boundaries, pages boundaries, model internals, slice imports, sagas imports, and circular dependencies.
  • Architecture Context: Documented guidance on core features, domain features, and the composition root to keep wiring centralized and predictable.
  • Deterministic checks: Run all checks and generate a comprehensive report to identify violations and maintain clean architecture.

Quick Start

Run the full architectural audit to verify boundaries and generate a report: node ./.claude/skills/arch-audit/scripts/run_all_checks.mjs node ./.claude/skills/arch-audit/scripts/generate_report.mjs

Frequently Asked Questions about arch-audit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce architectural boundaries in a TypeScript codebase?

Enforce architectural boundaries by running automated checks that detect violations between core, domain, and composition-root layers. arch-audit applies eight predefined rules covering core-to-domain dependencies, service imports, page boundaries, and circular dependencies, then generates a comprehensive report identifying all violations.

What dependency violations does an architecture audit check for?

Architecture audits check for eight types of violations: core importing from domain, unauthorized service imports, service boundary breaches, page boundary violations, model internal access, improper slice imports, saga imports, and circular dependencies across your codebase.

How do I generate an architecture report for my TypeScript project?

Run the audit scripts to detect violations and generate a report: execute run_all_checks.mjs to perform all eight architectural checks, then generate_report.mjs to compile results. The src/config directory is exempt as the composition root.

Can I run individual architecture checks instead of all at once?

Yes, each architectural check has a dedicated script available. You can run specific checks for core-domain dependencies, service boundaries, pages, model internals, slice imports, sagas, or circular dependencies individually rather than running all checks together.

What's the difference between architecture checks for services, pages, and slices?

Each layer has distinct boundary rules: services enforce import restrictions and internal boundaries, pages prevent cross-page dependencies, and slices control inter-slice imports. Architecture audits validate all three separately to maintain proper feature isolation across your codebase.

Do I need external dependencies to run architecture checks?

No external dependencies are required. arch-audit runs deterministically through dedicated Node scripts without external packages, making it lightweight and immediately executable in any TypeScript project with a src/config composition root.