cook-mobile
Cook — Mobile Workflow
Structured workflow for mobile projects. Every non-trivial task flows through ordered phases.
Plan → Design → Code → Review → Test
Memory Bank — Required for Every Session
At the start of EVERY session, read all files in memory-bank/:
projectbrief.md— Core requirements and goalsproductContext.md— Problem and solution contexttechContext.md— Technical setup and dependenciessystemPatterns.md— Architecture and design patternsactiveContext.md— Current work focus and recent changesprogress.md— Completed work and known issues
If memory-bank/ does not exist, create it with the files above based on what you learn from the codebase.
After completing work (end of Test phase or any stopping point), update:
activeContext.md— What was done, current state, next stepsprogress.md— Mark completed items, add new known issues
This ensures continuity across sessions. Never skip this step.
[PLAN] Plan
- Read requirements. Ask if ambiguous.
- Identify affected screens, navigation, and native modules.
- Break into subtasks. Define acceptance criteria for both iOS and Android.
- Identify platform-specific behavior needed.
Output: Numbered plan with affected screens and acceptance criteria. Rule: No code in this phase.
[DESIGN] Design
- Define screen components and navigation flow.
- Plan gestures, animations, and platform-specific UI.
- Identify shared vs platform-specific code.
Output: Screen hierarchy, navigation map, and platform-specific decisions. Rule: Match existing component patterns. Follow platform conventions.
[CODE] Code
- Build shared components first, then platform-specific code.
- Handle offline state, slow networks, and permission prompts.
- Use platform-specific patterns where needed (SafeAreaView, StatusBar, etc.).
- Test on both platforms during development.
Rules:
- Match existing component patterns and naming conventions.
- Handle both iOS and Android edge cases.
[REVIEW] Review
- Cross-platform — Works on both iOS and Android? Platform-specific edge cases handled?
- Performance — No JS thread blocking? FlatList/FlashList for long lists? Memoization where needed?
- UX — Proper keyboard avoidance? Touch targets >=44pt? Loading indicators?
- Permissions — Camera, location, notifications handled gracefully with denial fallbacks?
- Types — Props typed correctly? No
any?
Fix issues immediately. If layout/design is wrong, loop back to Design.
[TEST] Test
- Component tests — Test screen components and interactions.
- Platform test — Run on iOS simulator and Android emulator.
- Run full test suite and type checker.
Rule: Test user behavior across both platforms, not implementation details.
Iteration
If any phase reveals problems:
- Test failures from a bug → Fix in Code, re-run Review + Test.
- Review reveals missing requirements → Loop back to Plan.
- Design flaw found during Code → Loop back to Design.
- User feedback changes scope → Restart from Plan.
Always note which phase you're returning to and why.
Phase Markers
Prefix progress with the current phase:
[PLAN] Analyzing requirements...
[DESIGN] Defining screen flow...
[CODE] Implementing components...
[REVIEW] Self-reviewing changes...
[TEST] Running on simulators...