Skip to content

Provide MainScope factory #829

Closed
Closed
@qwwdfsad

Description

@qwwdfsad

We should provide factory method fun MainScope() = CoroutineScope(Dispatchers.Main + SupervisorJob()).

It fixes multiple issues (especially with the #828):

  1. Integration with UI components are simple both for implementing an interface and having it in a field
  2. It protects newcomers from async behaviour when it is launched from UI component
  3. It simplifies guides and documentation

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions