Loading...
Loading...
Cross-Layer Check
npx skill4agent add mindfold-ai/trellis check-cross-layerNote: This is a post-implementation safety net. Ideally, read the Pre-Implementation Checklist before writing code.
| Document | Purpose | Timing |
|---|---|---|
| Pre-Implementation Checklist | Questions before coding | Before writing code |
| Code Reuse Thinking Guide | Pattern recognition | During implementation |
| Verification check | After implementation |
git status
git diff --name-only| Layer | Common Locations |
|---|---|
| API/Routes | |
| Service/Business Logic | |
| Database/Storage | |
| UI/Presentation | |
| Utility | |
.trellis/spec/guides/cross-layer-thinking-guide.md# Search in source files (adjust extensions for your project)
grep -r "value-to-change" src/.trellis/spec/guides/code-reuse-thinking-guide.mdgrep -r "functionNamePattern" src/grep -r "patternYouChanged" src/grep -r "ConceptName" src/| Issue | Root Cause | Prevention |
|---|---|---|
| Changed one place, missed others | Didn't search impact scope | |
| Data lost at some layer | Didn't check data flow | Trace data source to destination |
| Type/schema mismatch | Cross-layer types inconsistent | Use shared type definitions |
| UI/output inconsistent | Same concept in multiple places | Extract shared constants |
| Similar utility exists | Didn't search first | Search before creating |
| Batch fix incomplete | Didn't verify all occurrences | grep after fixing |