check-cross-layer

Verifies code changes across data flow, reuse, imports, and consistency dimensions.

Updated Mar 24, 2026
One-click install
npx skills add https://github.com/yizhitangtongxue/opencode-switch --skill check-cross-layer-yizhitangtongxue
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: check-cross-layer
Source: https://github.com/yizhitangtongxue/opencode-switch/tree/main/.agents/skills/check-cross-layer
Command: npx skills add https://github.com/yizhitangtongxue/opencode-switch --skill check-cross-layer-yizhitangtongxue

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Most bugs come from unconsidered impact scope rather than lack of technical skill. This Skill provides a post-implementation verification checklist that catches missed files, broken data flows, and inconsistent changes before they ship. ## Core Features & Use Cases - Cross-Layer Data Flow Check: Traces read and write flows across API, service, database, and UI layers when changes touch 3 or more layers. - Code Reuse Verification: Uses grep-based searches to find duplicate constants, existing utilities, and incomplete batch modifications. - Import and Consistency Checks: Validates import paths, circular dependencies, and same-concept consistency across the codebase. - Use Case: After refactoring a shared label constant across several components, run this check to confirm every occurrence was updated and no duplicate definitions remain. ## Quick Start Ask the AI to run the cross-layer check on your current uncommitted changes and report which dimensions apply and any issues found.

Frequently Asked Questions about check-cross-layer

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

FAQPage Schema
How do I check if my code change affected other files?▼

Run git status and git diff --name-only to identify changed files, then use grep to search for the modified values or patterns across the source tree. This reveals all usage sites that may need matching updates.

How to verify cross-layer data flow in a code change?▼

Trace the read flow from database through service and API to UI, and the write flow in reverse. Confirm types and schemas pass correctly between layers, errors propagate to callers, and loading states are handled at each layer.

When should I run a post-implementation checklist?▼

Run it after finishing implementation but before committing, especially when changes touch three or more layers, modify shared constants, create new utility functions, or apply batch edits across multiple files.

How do I find duplicate constants before refactoring?▼

Search the source directory with grep for the exact value you plan to change. If two or more locations define the same value, extract it into a shared constant and update every usage site.

What are the limitations of a manual checklist-based code review?▼

A checklist only catches issues in the dimensions you select and depends on thorough grep searches. It does not execute tests or detect runtime behavior, so it should complement automated testing rather than replace it.