Liking cljdoc? Tell your friends :D

reanimated.core

An animation library for Reagent (ClojureScript). There is only one concept: A reaction that moves toward some target, each step triggers another update until it reaches the end state. The trigger occurs by touching a local atom a zero timeout, which changes the atom in the next Reagent render.

An animation library for Reagent (ClojureScript).
There is only one concept:
A reaction that moves toward some target,
each step triggers another update until it reaches the end state.
The trigger occurs by touching a local atom a zero timeout,
which changes the atom in the next Reagent render.
raw docstring

get-scrollcljs

Gets the current document y scroll position.

Gets the current document y scroll position.
sourceraw docstring

get-scroll-xcljs

(get-scroll-x)

Gets the current document x scroll position.

Gets the current document x scroll position.
sourceraw docstring

get-scroll-ycljs

(get-scroll-y)

Gets the current document y scroll position.

Gets the current document y scroll position.
sourceraw docstring

interpolate-argcljs

(interpolate-arg component x)
(interpolate-arg component x options)

Interpolates the argument of a component to x. Will call the given component with values approaching x. Options can contain duration (in milliseconds) and easing (a function of a b duration t).

Interpolates the argument of a component to x.
Will call the given component with values approaching x.
Options can contain duration (in milliseconds)
and easing (a function of a b duration t).
sourceraw docstring

interpolate-ifcljs

(interpolate-if condition a b)
(interpolate-if condition a b options)

Interpolates between two values when the conditon changes. Takes a condition ratom to watch, and 2 vectors or values to render. Options can contain duration (in milliseconds) and easing (a function of a b duration t).

Interpolates between two values when the conditon changes.
Takes a condition ratom to watch, and 2 vectors or values to render.
Options can contain duration (in milliseconds)
and easing (a function of a b duration t).
sourceraw docstring

interpolate-tocljs

(interpolate-to x)
(interpolate-to x options)

Interpolates toward new values. Takes a ratom which stores a numeric value. Options can contain duration (in milliseconds) and easing (a function of a b duration t).

Interpolates toward new values.
Takes a ratom which stores a numeric value.
Options can contain duration (in milliseconds)
and easing (a function of a b duration t).
sourceraw docstring

intervalcljs

(interval f t)

Call function f every period t while mounted in the DOM.

Call function f every period t while mounted in the DOM.
sourceraw docstring

mouse-watchercljs

(mouse-watcher ratom)

Returns a map suitable for merging with component properties, that will keep a given ratom updated with the mouseover status.

Returns a map suitable for merging with component properties,
that will keep a given ratom updated with the mouseover status.
sourceraw docstring

pop-whencljs

(pop-when condition then)
(pop-when condition then options)

Wraps a component to animate creation and destruction. Takes a condition ratom and a vector or value to be rendered. Options can contain duration (milliseconds) and easing (a function that takes a b duration t).

Wraps a component to animate creation and destruction.
Takes a condition ratom and a vector or value to be rendered.
Options can contain duration (milliseconds)
and easing (a function that takes a b duration t).
sourceraw docstring

scrollcljs

A ratom for watching the current document y scroll, will be updated when there is a scroll event.

A ratom for watching the current document y scroll,
will be updated when there is a scroll event.
sourceraw docstring

scroll-xcljs

A ratom for watching the current document x scroll, will be updated when there is a scroll event.

A ratom for watching the current document x scroll,
will be updated when there is a scroll event.
sourceraw docstring

scroll-ycljs

A ratom for watching the current document y scroll, will be updated when there is a scroll event.

A ratom for watching the current document y scroll,
will be updated when there is a scroll event.
sourceraw docstring

slow-revealcljs

(slow-reveal t xs)
source

springcljs

(spring x2)
(spring x2 options)

Useful for wrapping a value in your component to make it springy. Returns a reaction that will take values approaching x2, updating every time Reagent calls requestAnimationFrame. Integrates a physical spring simulation for each step. Options can contain: from - a value to start from (initial value is used if absent). velocity of the mass on the spring (initially 0 if absent). mass, stiffness, damping of the spring.

Useful for wrapping a value in your component to make it springy.
Returns a reaction that will take values approaching x2,
updating every time Reagent calls requestAnimationFrame.
Integrates a physical spring simulation for each step.
Options can contain:
from - a value to start from (initial value is used if absent).
velocity of the mass on the spring (initially 0 if absent).
mass, stiffness, damping of the spring.
sourceraw docstring

timelinecljs

(timeline x & xs)

Given a sequence of inputs, will consume them depending on their type: numbers will be a sleep in milliseconds functions will be called with no arguments vectors will be rendered as reagent components.

Given a sequence of inputs, will consume them depending on their type:
numbers will be a sleep in milliseconds
functions will be called with no arguments
vectors will be rendered as reagent components.
sourceraw docstring

timeoutcljs

(timeout f t)

Call function f period t in milliseconds after being mounted in the DOM, only if still mounted.

Call function f period t in milliseconds after being mounted in the DOM,
only if still mounted.
sourceraw docstring

toggle-handlercljs

(toggle-handler ratom)

Creates an event handler that will toggle a given ratom.

Creates an event handler that will toggle a given ratom.
sourceraw docstring

watchcljs

(watch r f)

Watch a ref only while mounted in the DOM.

Watch a ref only while mounted in the DOM.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close