Hi! What is the best way to implement an independe...
# compose
m
Hi! What is the best way to implement an independent composable? In my case, I have a feature to send debug data. This feature show a dialog to send debug data (with loading/success/error state). This dialog can be use in severals screens. Today, I need to keep the state of the dialog and the sending data. I thought to create a ViewModel for this component which handle it. Then each screen which required this feature will just need to instantiate the viewmodel then pass it to the composable. What do you think ? Bad idea ?