From android-developer
Creates an Android ViewModel with sealed UI state, StateFlow, Hilt injection, and coroutine-based data loading for proper state management.
How this command is triggered — by the user, by Claude, or both
Slash command
/android-developer:add-viewmodelThe summary Claude sees in its command listing — used to decide when to auto-load this command
# /add-viewmodel - Add ViewModel Create an Android ViewModel with proper state management and data flow. ## Steps 1. Ask the user for the ViewModel name and the data it manages 2. Create the ViewModel class extending androidx.lifecycle.ViewModel 3. Define sealed interfaces for UI state, UI events, and side effects 4. Initialize StateFlow for the UI state with a sensible default 5. Add repository or use case dependencies via constructor injection (Hilt) 6. Implement event handling: map user actions to state changes 7. Add error handling with proper error state propagation 8. Implement dat...
Create an Android ViewModel with proper state management and data flow.
6plugins reuse this command
First indexed Mar 30, 2026
npx claudepluginhub samuelj90/awesome-claude-code-toolkit --plugin android-developer/add-viewmodelCreates an Android ViewModel with sealed UI state, StateFlow, Hilt injection, and coroutine-based data loading for proper state management.
/create-viewGenerates a SwiftUI view with proper MVVM architecture, state management, accessibility, dark mode, and preview configurations.
/f5-mobileGenerates mobile app screens, widgets, models, services, and more for auto-detected stack (Flutter, React Native Expo, Android Kotlin, iOS Swift). Outputs files list, architecture diagram, next steps.
/android-reviewReviews Android code for Kotlin style, Jetpack Compose patterns, MVI correctness, security issues, and performance. Provides actionable feedback.