(broadcast-sync! _ _ & _)
dummy broadcast-sync!
dummy broadcast-sync!
(dispatch! _ _ _ & _)
dummy dispatch!
dummy dispatch!
(dispatch! reconciler event & args)
Invoke an event on particular controller asynchronously
(citrus/dispatch! reconciler :users :load "id")
Arguments
reconciler - an instance of Reconciler event - a dispatch value of a method defined in the controller args - arguments to be passed into the controller
Invoke an event on particular controller asynchronously (citrus/dispatch! reconciler :users :load "id") Arguments reconciler - an instance of Reconciler event - a dispatch value of a method defined in the controller args - arguments to be passed into the controller
(dispatch-sync! _ _ _ & _)
dummy dispatch-sync!
dummy dispatch-sync!
(dispatch-sync! reconciler event & args)
Invoke an event on particular controller synchronously
(citrus/dispatch! reconciler :users :load "id")
Arguments
reconciler - an instance of Reconciler event - a dispatch value of a method defined in the controller args - arguments to be passed into the controller
Invoke an event on particular controller synchronously (citrus/dispatch! reconciler :users :load "id") Arguments reconciler - an instance of Reconciler event - a dispatch value of a method defined in the controller args - arguments to be passed into the controller
(reconciler {:keys [state]})
Accepts a hash of :state
atom & :resolvers
hash of subscription resolvers where keys are subscription path vectors and values are data resolving functions
{:state (atom {})}
Returns a hash of resolvers
and state
atom which will be populated with resolved subscriptions data during rendering
Accepts a hash of `:state` atom & `:resolvers` hash of subscription resolvers where keys are subscription path vectors and values are data resolving functions {:state (atom {})} Returns a hash of `resolvers` and `state` atom which will be populated with resolved subscriptions data during rendering
(reconciler {:keys [state handler effect-handlers batched-updates
chunked-updates debug?]}
&
{:as options})
Creates an instance of Reconciler
(citrus/reconciler {:state (atom {}) :handler handler :effect-handlers {:http effects/http} :batched-updates f :chunked-updates f})
Arguments
config - a map of
state - app state atom
handler - event handler
effect-handlers - a hash of effects handlers
batched-updates - a function used to batch reconciler updates, defaults to js/requestAnimationFrame
chunked-updates - a function used to divide reconciler update into chunks, doesn't used by default
Returned value supports deref, watches and metadata.
The only supported option is :meta
Creates an instance of Reconciler (citrus/reconciler {:state (atom {}) :handler handler :effect-handlers {:http effects/http} :batched-updates f :chunked-updates f}) Arguments config - a map of state - app state atom handler - event handler effect-handlers - a hash of effects handlers batched-updates - a function used to batch reconciler updates, defaults to `js/requestAnimationFrame` chunked-updates - a function used to divide reconciler update into chunks, doesn't used by default Returned value supports deref, watches and metadata. The only supported option is `:meta`
(subscription reconciler path)
(subscription {:keys [state]} path reducer)
Create a subscription to state updates
(citrus/subscription reconciler [:users 0] (juxt [:fname :lname]))
Arguments
reconciler - reconciler hash path - a vector which describes a path into resolver's result value reducer - an aggregate function which computes a materialized view of data behind the path
Create a subscription to state updates (citrus/subscription reconciler [:users 0] (juxt [:fname :lname])) Arguments reconciler - reconciler hash path - a vector which describes a path into resolver's result value reducer - an aggregate function which computes a materialized view of data behind the path
(subscription reconciler path)
(subscription reconciler path reducer)
Create a subscription to state updates
(citrus/subscription reconciler [:users 0] (juxt [:fname :lname]))
Arguments
reconciler - an instance of Reconciler path - a vector which describes a path into reconciler's atom value reducer - an aggregate function which computes a materialized view of data behind the path
Create a subscription to state updates (citrus/subscription reconciler [:users 0] (juxt [:fname :lname])) Arguments reconciler - an instance of Reconciler path - a vector which describes a path into reconciler's atom value reducer - an aggregate function which computes a materialized view of data behind the path
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close