entryProvider

inline fun <T : Any> entryProvider(noinline fallback: (unknownScreen: T) -> NavEntry<T> = { throw IllegalStateException("Unknown screen $it") }, builder: EntryProviderScope<T>.() -> Unit): (T) -> NavEntry<T>

Provides a EntryProviderScope to build an entryProvider that provides NavEntries.

Return

an entryProvider that provides the NavEntry associated with a given key

Parameters

fallback

the fallback NavEntry when the provider cannot find an entry associated with a given key on the backStack

builder

the DSL extension that provides a EntryProviderScope to build an entryProvider that provides NavEntries.

Type Parameters

T

the type of the NavEntry key