[Question] Is it best practice to have live data in data Layer
MahmoudMabrok opened this issue · 1 comments
MahmoudMabrok commented
[Question] Is it best practice to have live data in data Layer
ahmedeltaher commented
No, it is not a best practice, livedata is life cycle awareness observable, you don't need that in data layer, I recommend to use flow which is cold observable in the data layer.
In this sample we use Kotlin flow.