ViewModel Scaffold
Create a view model with typed state and async actions.
When to Use
- •When a view needs business logic or async data.
Inputs
- •ViewModel name
- •State shape
- •Dependencies and async actions
Instructions
- •Define state model and public API.
- •Implement async actions using
async/await. - •Add unit tests for state transitions.
Output
- •ViewModel file and XCTest coverage.