TypedReduxStore

open class TypedReduxStore<S : Any, A : RAction>(val store: <Error class: unknown class><S, A>)

A class implementing redux pattern backed by the Redux Kotlin library.

Parameters

S

redux state type

A

redux action type

store

a native typed redux store

Constructors

Link copied to clipboard
fun <S : Any, A : RAction> TypedReduxStore(store: <Error class: unknown class><S, A>)

Creates a Redux store with given reducer function and initial state.

Functions

Link copied to clipboard
fun dispatch(action: A)

Dispatches a synchronous action object.

fun dispatch(actionCreator: ActionCreator<A, S>)

Dispatches an asynchronous action function.

Link copied to clipboard
open fun getState(): S
Link copied to clipboard
open fun subscribe(observer: (S) -> Unit): () -> Unit

Properties

Link copied to clipboard
val store: <Error class: unknown class><S, A>