3. Pass dependencies as parameters to composable functions when possible
4. Use remember { } for component-scoped dependencies
The Compose team recommends keeping UI components pure and moving dependencies to the ViewModel or other business logic layers.
Join thousands of Android developers getting the most entertaining & insightful Jetpack Compose newsletter
• Curated insights in 5 minutes or less
• Entertaining analysis of Android happenings
• Insider tips from top developers
• Hidden gems you won't find elsewhere
"
"Thanks for taking the time and energy to do it so well!"
— Sebastian Lobato Genco
Android Engineer @ Q42
Join thousands of Android devs who look forward to Dispatch every week
The #1 destination for all things Jetpack Compose 🤖📱