vittrade-button-wiring-audit

Audits Flutter onPressed and onTap handlers to detect dead buttons in Dart code.

Updated May 19, 2026
One-click install
npx skills add https://github.com/LonelyTraderBay/vittrade-flutter --skill vittrade-button-wiring-audit-lonelytraderbay
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vittrade-button-wiring-audit
Source: https://github.com/LonelyTraderBay/vittrade-flutter/tree/main/.agents/skills/vittrade-button-wiring-audit
Command: npx skills add https://github.com/LonelyTraderBay/vittrade-flutter --skill vittrade-button-wiring-audit-lonelytraderbay

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Flutter UI batches often leave buttons with empty or null onPressed and onTap handlers, creating dead actions that route audits cannot catch. This Skill scans Dart feature modules and classifies every candidate handler so reviewers can distinguish genuinely broken buttons from intentional disabled or dev-only states. ## Core Features & Use Cases - Exhaustive Handler Scan: Searches a scoped Dart directory for every empty, async-empty, and null onPressed/onTap pattern without sampling. - Context Classification: Labels each finding as broken, needs_review, or legitimate based on enclosing widgets, comments, route reachability, and sibling handlers. - Ledger Reporting: Produces a structured markdown ledger with file, line, implied action, and evidence, optionally persisted under flutter_app/run-artifacts/. - Use Case: After a large UI refactor of a trading feature module, run the audit on flutter_app/lib/features/portfolio/ to confirm no visible button lost its action before release. ## Quick Start Audit the portfolio feature module for dead button handlers and report a classified ledger of broken, needs-review, and legitimate findings.

Frequently Asked Questions about vittrade-button-wiring-audit

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

FAQPage Schema
How do I find dead buttons in a Flutter app?

Scan Dart source for onPressed and onTap handlers with empty bodies or null values, then classify each by reading the enclosing widget and comments. This audit automates that scan per feature module and reports a classified ledger.

How to audit onPressed handlers after a Flutter UI refactor?

Scope the audit to the changed feature module under flutter_app/lib/features/, run the exhaustive candidate scan, and review the broken section of the ledger. Each finding includes file, line, implied action, and classification evidence.

Does a null onPressed always mean a broken Flutter button?

No. A null onPressed is legitimate when the widget visibly renders a disabled state, is gated by a conditional terminal state, or belongs to an internal dev surface. The audit classifies these as legitimate rather than broken.

Can this audit modify Flutter code to fix dead buttons?

No. The audit is strictly read-only and only reports findings with evidence. It never edits application code; fixes must be implemented separately by a developer.

Why does a navigation route audit not catch dead buttons?

Route audits only verify navigation targets exist, not that non-navigation buttons perform actions. Buttons triggering local state changes, dialogs, or data operations need a dedicated handler-wiring audit like this one.