Liking cljdoc? Tell your friends :D

react-repl.core


all-fiberscljs

(all-fibers)
(all-fibers id)

Returns a seq of all the fibers. Optionally provide a root ID in the case that you have multiple React roots in the environment.

Returns a seq of all the fibers.
Optionally provide a root ID in the case that you have multiple React roots
in the environment.
raw docstring

child-fibercljs

(child-fiber fiber)

Returns the direct child of the fiber.

Returns the direct child of the fiber.
raw docstring

childrencljs

(children fiber)

Returns all of the direct children of this fiber.

Returns all of the direct children of this fiber.
raw docstring

current-fibercljs

(current-fiber)
(current-fiber id)

Gets the current fiber rendered at the root. If no root-id is passed in, assumes that it is 1, which is standard if only a single React root exists in the JS environment.

Gets the current fiber rendered at the root.
If no root-id is passed in, assumes that it is `1`, which is standard if
only a single React root exists in the JS environment.
raw docstring

display-typecljs

(display-type fiber)

Returns a human-readable version of the fiber type.

Returns a human-readable version of the fiber type.
raw docstring

fiber->mapcljs

(fiber->map fiber)

Returns the fiber as a map for display.

Returns the fiber as a map for display.
raw docstring

fiber?cljs

(fiber? x)

Returns true or false whether x is a React fiber.

Returns true or false whether `x` is a React fiber.
raw docstring

findcljs

(find type)
(find type root-id)

Find the first fiber currently rendered that use a component type.

Find the first fiber currently rendered that use a component type.
raw docstring

find-allcljs

(find-all type)
(find-all type root-id)

Find all currently rendered fibers that use a component type.

Find all currently rendered fibers that use a component type.
raw docstring

has-child?cljs

(has-child? fiber)

Returns true or false whether the fiber has a child

Returns true or false whether the fiber has a child
raw docstring

hook-depscljs

(hook-deps hook)

Returns the last rendered deps of a hook, if applicable.

Returns the last rendered deps of a hook, if applicable.
raw docstring

hook-dispatchcljs

(hook-dispatch {:keys [dispatch] :as _hook} & args)

Dispatches a change with a useState or useReducer hook.

Dispatches a change with a useState or useReducer hook.
raw docstring

parentcljs

(parent fiber)

Returns the direct parent of the fiber.

Returns the direct parent of the fiber.
raw docstring

propscljs

(props fiber)

Returns the current props of the fiber.

Returns the current props of the fiber.
raw docstring

set-statecljs

(set-state fiber f)

Tries to set the state of a fiber constructed out of a class component. Returns true if fiber is of a valid class component and nil if not.

Tries to set the state of a fiber constructed out of a class component.
Returns `true` if fiber is of a valid class component and `nil` if not.
raw docstring

sibling-fibercljs

(sibling-fiber fiber)

Returns the sibling to the right of the fiber.

Returns the sibling to the right of the fiber.
raw docstring

siblingscljs

(siblings fiber)

Returns all siblings to hte right of the fiber.

Returns all siblings to hte right of the fiber.
raw docstring

statecljs

(state fiber)

Returns the current state (hooks or class component state) of the fiber.

Returns the current state (hooks or class component state) of the fiber.
raw docstring

typecljs

(type fiber)

Returns the element type (class, function component, etc.) used to construct the fiber.

Returns the element type (class, function component, etc.) used to construct
the fiber.
raw docstring

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

× close