Liking cljdoc? Tell your friends :D

show.core

cljs

This React wrapper has a few concerns:

  • Build React component and delegate lifecycle methods to supplied cljs functions
  • Provide functions to update internal component state
  • Provide render functions
This React wrapper has a few concerns:
- Build React component and delegate lifecycle methods to supplied cljs functions
- Provide functions to update internal component state
- Provide render functions
raw docstring

assoc!cljs

(assoc! component & kvs)

Replaces values in the component's local state. Delegates to clojurescript's assoc

Replaces values in the component's local state. Delegates to clojurescript's
assoc
sourceraw docstring

assoc-in!cljs

(assoc-in! component ks v)

Replaces a value in the component's local nested associative state, where ks is a sequence of keys and v is the new value. If any levels do not exist, hash-maps will be created. Delegates to clojurescript's assoc-in.

Replaces a value in the component's local nested associative state, where ks
is a sequence of keys and v is the new value. If any levels do not exist,
hash-maps will be created. Delegates to clojurescript's assoc-in.
sourceraw docstring

componentclj/smacro

(component & forms)

Build anonoymous component class

Build anonoymous component class
sourceraw docstring

create-refcljs

(create-ref)
source

defcomponentclj/smacro

(defcomponent name & forms)

Defines a fn to create a React component

Defines a fn to create a React component
sourceraw docstring

dissoc!cljs

(dissoc! component k & ks)

Dissociates entries from the component's nested associative structure. Can accept multiple keys to remove. Delegates to clojurescript's dissoc

Dissociates entries from the component's nested associative structure. Can
accept multiple keys to remove. Delegates to clojurescript's dissoc
sourceraw docstring

dissoc-in!cljs

(dissoc-in! component ks)

Dissociates an entry from the component's nested associative structure. ks can be a sequence of keys.

Dissociates an entry from the component's nested associative structure. ks
can be a sequence of keys.
sourceraw docstring

force-update!cljs

(force-update! component)
(force-update! component cb)

Forces an update. This should only be invoked when it is known with certainty that we are not in a DOM transaction.

You may want to call this when you know that some deeper aspect of the component's state has changed but any state change functions were not called.

This will not invoke should-update, but it will invoke will-update and did-update.

Forces an update. This should only be invoked when it is known with
certainty that we are **not** in a DOM transaction.

You may want to call this when you know that some deeper aspect of the
component's state has changed but any state change functions were not
called.

This will not invoke `should-update`, but it will invoke `will-update` and
`did-update`.
sourceraw docstring

get-nodecljs

(get-node component)
(get-node component name)

Get the node of the current component, or if a name is passed in, lookup any refs that have been declared on child dom elements

Get the node of the current component, or if a name is passed in,
lookup any refs that have been declared on child dom elements
sourceraw docstring

get-propscljs

(get-props component)
(get-props component ks)

Returns the value of the components inherited nested associative structure. ks is an optional property that gives quick access to a get-in call

Returns the value of the components inherited nested associative structure.
ks is an optional property that gives quick access to a get-in call
sourceraw docstring

get-statecljs

(get-state component)
(get-state component ks)

Returns the value of the components owned state nested associative structure. ks is an optional property that gives quick access to a get-in call

Returns the value of the components owned state nested associative structure.
ks is an optional property that gives quick access to a get-in call
sourceraw docstring

inject-static-methodscljs

(inject-static-methods obj)
source

render-componentcljs

source

render-to-domcljs

(render-to-dom component dom)

Bootstrap the component and inject it into the dom on the next render cycle

Bootstrap the component and inject it into the dom on the next render
cycle
sourceraw docstring

render-to-static-markupcljs

(render-to-static-markup element)

Render a React element to its initial HTML, except this doesn’t create extra DOM attributes that React uses internally

Render a React element to its initial HTML, except this doesn’t create
extra DOM attributes that React uses internally
sourceraw docstring

render-to-stringcljs

(render-to-string element)

Render a React element to its initial HTML

Render a React element to its initial HTML
sourceraw docstring

reset!cljs

(reset! component val)

Sets the new value of the components state to val without regard to the current value. Takes optional callback function to be called when value is merged into the render state

Sets the new value of the components state to val without regard to the
current value. Takes optional callback function to be called when value is
merged into the render state
sourceraw docstring

swap!cljs

(swap! component f & args)

Apply f over the state of the included component. Use this if you want to make multiple changes to the state of your component

Apply f over the state of the included component. Use this if you want
to make multiple changes to the state of your component
sourceraw docstring

update!cljs

(update! component k f & args)

Update a value in the component's local show structure.

Update a value in the component's local show structure.
sourceraw docstring

update-in!cljs

(update-in! component ks f & args)

'Updates' a value in the component's local nested associative structure, where ks is a sequence of keys and f is a function that will take the old value and any supplied args and return the new value, and returns a new nested structure. If any levels do not exist, hash-maps will be created.

'Updates' a value in the component's local nested associative structure,
where ks is a sequence of keys and f is a function that will take the old
value and any supplied args and return the new value, and returns a new
nested structure. If any levels do not exist, hash-maps will be created.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close