Package-level declarations

Types

Link copied to clipboard
annotation class FragmentComponent

Mark it as a type to inject into Fragment.

Link copied to clipboard

Get a Fragment's CoroutineScope that the same as lifecycleScope.

Link copied to clipboard

Get a Fragment view's CoroutineScope that the same as Fragment.viewLifecycleOwner.lifecycleScope.

Functions

Link copied to clipboard
inline fun <VM : ViewModel> Fragment.injectActivityViewModels(qualifier: Any? = null, noinline extrasProducer: () -> CreationExtras? = null): Lazy<VM>

Returns a Lazy delegate to access parent activity's ViewModel provided by Koject

Link copied to clipboard
inline fun <VM : ViewModel> Fragment.injectViewModels(qualifier: Any? = null, noinline ownerProducer: () -> ViewModelStoreOwner = { this }, noinline extrasProducer: () -> CreationExtras? = null): Lazy<VM>

Returns a Lazy delegate to access the Fragment's ViewModel provided by Koject

Link copied to clipboard
inline fun <VM : ViewModel> Fragment.lazyActivityViewModels(qualifier: Any? = null, noinline extrasProducer: () -> CreationExtras? = null): Lazy<VM>

Returns a Lazy delegate to access parent activity's ViewModel provided by Koject

Link copied to clipboard
inline fun <VM : ViewModel> Fragment.lazyViewModels(qualifier: Any? = null, noinline ownerProducer: () -> ViewModelStoreOwner = { this }, noinline extrasProducer: () -> CreationExtras? = null): Lazy<VM>

Returns a Lazy delegate to access the Fragment's ViewModel provided by Koject