phxboundaries

Solid

Analyze Phoenix context boundaries and module coupling via mix xref. Use when checking cross-context calls, validating dependencies, before splitting modules, or reviewing architecture.

Code & Development 384 stars 25 forks Updated 4 days ago MIT

Install

View on GitHub

Quality Score: 95/100

Stars 20%
86
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Phoenix Context Boundary Validation Analyze module dependencies to ensure clean context separation and proper architectural boundaries. ## Usage ``` /phx:boundaries # Check for violations /phx:boundaries --assess # Score context health (0-100) /phx:boundaries --fix # Suggest fixes for violations ``` ## `--assess` Mode: Context Health Score Evaluate overall boundary health with a quantified score. ### Metrics Calculated | Metric | Healthy Range | Red Flag | Weight | |--------|---------------|----------|--------| | Modules per context | 3-15 | >20 or <2 | 20% | | Public API surface | 5-30 funcs | >40 funcs | 15% | | Fan-out (contexts called) | 1-4 | >6 | 20% | | Fan-in (called by contexts) | 1-6 | >10 | 15% | | Circular dependencies | 0 | >0 | 15% | | Boundary violations | 0 | >0 | 15% | ### Commands for Assessment Use Glob to count `.ex` files per context directory under `lib/my_app/*/`. Use Grep to count public function definitions per context file under `lib/my_app/*.ex`. Run `mix xref graph --format stats` for dependency analysis. Run `mix xref graph --format cycles --label compile` for compile-time circular dependencies. ### Output Format ```markdown ## Context Health Assessment ### Overall Score: 82/100 (Good) | Context | Modules | API | Fan-Out | Fan-In | Score | |---------|---------|-----|---------|--------|-------| | Accounts | 5 | 12 | 2 | 4 | 95 | | Orders | 18 | 45 | 8 | 3 | 62 | | Shared | 2 | 8 | 0 | 12 | 78 | ### Issues Fou...

Details

Author
oliver-kriska
Repository
oliver-kriska/claude-elixir-phoenix
Created
3 months ago
Last Updated
4 days ago
Language
Python
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category