Package-level declarations
Types
Link copied to clipboard
Link copied to clipboard
Threadsafe wrapper for ReduxKotlin store that synchronizes access to each function using kotlinx.AtomicFu [https://github.com/Kotlin/kotlinx.atomicfu] Allows all store functions to be accessed from any thread. This does have a performance impact for JVM/Native. TODO more info at https://ReduxKotlin.org
Functions
Link copied to clipboard
Converts a given Store to a ThreadSafeStore.
Link copied to clipboard
Link copied to clipboard
fun <State> createThreadSafeStore(reducer: Reducer<State>, preloadedState: State, enhancer: StoreEnhancer<State>? = null): Store<State>
Creates a SYNCHRONIZED, THREADSAFE Redux store that holds the state tree. The only way to change the data in the store is to call dispatch()
on it.
Link copied to clipboard
Creates a store enhancer that wraps a Redux store in a synchronization object, causing access to store methods to be synchronized.
Link copied to clipboard
inline fun <State, Action : Any> createTypedThreadSafeStore(crossinline reducer: TypedReducer<State, Action>, preloadedState: State, noinline enhancer: StoreEnhancer<State>? = null): TypedStore<State, Action>
Creates a thread-safe TypedStore. For further details see the matching createThreadSafeStore.