ground-android icon indicating copy to clipboard operation
ground-android copied to clipboard

[Code health] Convert all `@Singleton`s to Kotlin `object`s

Open scolsen opened this issue 3 years ago • 0 comments

Kotlin has nice native support for declaring singletons using object declarations. Unfortunately, Dagger does not support injecting classes into objects, which at the moment pretty much prevents us from using an object for any construct that needs to depend on classes we'd normally inject.

If we convert all the classes we've currently marked as @Singleton into objects we can drop the several injections which should make kotlin code easier to refactor.

scolsen avatar Oct 06 '22 18:10 scolsen