Install
$ agentstack add skill-mdazadhossain95-flutter-agent-skills-flutter-optimize-codebase ✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
About
Optimize Flutter Codebase
Purpose
Use this skill to audit and improve an existing Flutter codebase with practical, high-impact optimizations.
Activation
Activate when user asks to optimize, improve, harden, refactor, or speed up a Flutter app or a specific module.
Input Collection
Capture minimum context first:
- Scope: whole app, feature folder, or specific files.
- Target: performance, architecture, code quality, app size, stability, testability, or all.
- Optimization mode: quick, standard, deep.
- Risk tolerance: low-risk only or allow medium refactors.
If scope is missing, default to project-level scan.
Optimization Modes
- Quick mode: fast audit + top 5 improvements.
- Standard mode: prioritized plan + key code changes.
- Deep mode: broader refactor roadmap with staged implementation plan.
Optimization Workflow
Follow this order:
1) Baseline and hotspots
- Map project structure and critical execution paths.
- Identify hotspots in startup path, navigation, rendering-heavy screens,
network/data pipeline, and state updates.
2) Architecture and boundaries
- Check separation of presentation, logic, and data layers.
- Detect coupling, duplicated logic, and module boundary leaks.
- Recommend consolidation where appropriate.
3) State management efficiency
- Identify excessive rebuild patterns and state over-scoping.
- Ensure state ownership is close to consumers where possible.
- Recommend selector/listener granularity improvements.
4) Rendering and UI performance
- Look for expensive build methods and unnecessary widget rebuilds.
- Prefer const constructors where safe.
- Suggest list virtualization patterns and image handling improvements.
5) Network, caching, and persistence
- Evaluate API call strategy, retry behavior, and error handling.
- Recommend caching and offline-first patterns where relevant.
- Validate model parsing path and background processing suitability.
6) Reliability and error handling
- Identify weak async error handling and null-safety risks.
- Ensure domain-level error mapping and user-safe fallbacks.
7) App size and release readiness
- Recommend app-size analysis and dependency pruning.
- Flag large assets, redundant packages, and avoidable transitive bloat.
8) Testing and maintainability
- Detect missing tests in critical modules.
- Recommend minimum unit/widget/integration coverage targets by risk.
Output Format
Return in this structure:
- Optimization Scope and Mode
- Findings (ordered by impact)
- Recommended Changes (ordered by effort and risk)
- Quick Wins (can do now)
- Medium Refactors (next)
- Validation Checklist (how to verify improvements)
- Optional Next Iteration Plan
Behavior Rules
- Prioritize evidence-backed findings from actual code.
- Avoid vague suggestions not tied to observed patterns.
- For each recommendation, include expected impact and risk level.
- Prefer incremental changes before large rewrites.
- Keep business behavior unchanged unless user explicitly asks otherwise.
Risk Labels
Use these labels for each recommendation:
- Low: safe local changes, minimal regression risk.
- Medium: structural changes with moderate validation required.
- High: broad refactors requiring staged rollout and tests.
Validation Checklist
Before final response, ensure:
- Findings are prioritized by impact.
- Each recommendation has risk label and expected result.
- Suggested changes are scoped to user-selected area.
- A practical verify plan is included (tests, profiling, runtime checks).
Completion Template
Use this response layout:
- Scope:
- Mode:
- Top Findings:
- Recommended Changes:
- Verification Steps:
- Next Iteration:
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: mdazadhossain95
- Source: mdazadhossain95/flutter-agent-skills
- License: MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet — be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.