Khan
10/31/2019, 9:47 AMMartin Nordholts
10/31/2019, 11:38 AMrepository
by inheriting from : CoroutineScope by MainScope()
, then you can launch
from within your repository
instead of from outside itPaul Woitaschek
11/01/2019, 7:09 AMMartin Nordholts
11/01/2019, 7:19 AMprivate val coroutineScope = CoroutineScope(SupervisorJob() + Dispatchers.Main)
and use coroutineScope.launch
Khan
11/01/2019, 9:23 AMMartin Nordholts
11/01/2019, 9:25 AMKhan
11/01/2019, 9:28 AMMartin Nordholts
11/01/2019, 9:34 AMKhan
11/02/2019, 11:36 PMMartin Nordholts
11/03/2019, 10:31 AMIt creates a new scope inside ViewModelNo one has talked about creating a scope in a ViewModel.