CoroutineScope 팩토리 함수

interface CoroutineScope {
    val coroutineContext: CoroutineContext
}
class SomeClass : CoroutineScope {
    override val coroutineContext: CoroutineContext = Job()
    
    fun onStart() {
        launch {
            ..
        }
    }
}
class SomeClass {
    val scope: CoroutineScope = ...
    
    fun onStart() {
        scope.launch {
            ...
        }
    }
}

안드로이드에서 스코프 만들기

scope.coroutineContext.cancelChildren()

viewModelScope와 lifecycleScope

궁금한 부분