(children component)
Returns the children of the component
.
Returns the children of the `component`.
(class-methods ast)
(client component)
Returns the environment of component
.
Returns the environment of `component`.
(component? x)
Returns true if the argument is an Apollo component.
Returns true if the argument is an Apollo component.
(conform! spec data)
Like clojure.spec.alpha/conform
, but raises an exception if data
doesn't conform to spec
.
Like `clojure.spec.alpha/conform`, but raises an exception if `data` doesn't conform to `spec`.
(create-element class & [env props & children])
Create a React element of class
for env
, props
and children
.
Create a React element of `class` for `env`, `props` and `children`.
(defui class-sym & methods)
Define a Relay component.
Define a Relay component.
(defui* form)
(defui* env class-sym methods)
Define a Relay component.
Define a Relay component.
(emit-constructor env ast)
Emit the constructor of the component.
Emit the constructor of the component.
(env component)
(env component & ks)
Returns the environment of component
.
Returns the environment of `component`.
(fetch-more! component id & [opts])
Fetch more results for the given query id
.
Fetch more results for the given query `id`.
(fragments component)
(fragments component & ks)
Returns the GraphQL fragments of component
.
Returns the GraphQL fragments of `component`.
(component-will-receive-props this next-props)
(should-component-update this next-props next-state)
(component-did-mount this)
(component-did-update this prev-props prev-state)
(component-will-update this next-props next-state)
(render this)
(init-local-state this)
(component-will-unmount this)
(component-will-mount this)
(fragment this)
Returns the GraphQL fragments of the component.
Returns the GraphQL fragments of the component.
(mutation this)
Returns the GraphQL mutations of the component.
Returns the GraphQL mutations of the component.
(query this)
Returns the GraphQL query of the component.
Returns the GraphQL query of the component.
(react-key this props)
Returns the React key of the component.
Returns the React key of the component.
(variables this props query)
Returns the GraphQL variables for the query
.
Returns the GraphQL variables for the `query`.
(mutate! component id & [opts])
Evaluate the component
s GraphQL mutation with the given id
using
opts
and return a promise.
Evaluate the `component`s GraphQL mutation with the given `id` using `opts` and return a promise.
(mutations component)
(mutations component & ks)
Returns the GraphQL mutations from component
..
Returns the GraphQL mutations from `component`..
(props component)
(props component & ks)
Returns the props of component
.
Returns the props of `component`.
(prototype-methods ast)
(queries component)
(queries component & ks)
(reset-store! component)
Reset the client store.
Reset the client store.
(set-state! component new-state)
Set the component local state of the component. Analogous to React's setState.
Set the component local state of the component. Analogous to React's setState.
(set-variables! component query variables & [opts])
Set the variables
of the query
.
Set the `variables` of the `query`.
(specify-class-prototype! class)
(state component)
(state component & ks)
Get a component's local state. May provide a single key or a sequential collection of keys for indexed access into the component's local state.
Get a component's local state. May provide a single key or a sequential collection of keys for indexed access into the component's local state.
(subscribe-queries component props)
Subscribe to all queries of component
.
Subscribe to all queries of `component`.
(unsubscribe-queries component)
Unsubscribe from all queries of component
.
Unsubscribe from all queries of `component`.
(update-state! component f)
(update-state! component f arg0)
(update-state! component f arg0 arg1)
(update-state! component f arg0 arg1 arg2)
(update-state! component f arg0 arg1 arg2 arg3)
(update-state! component f arg0 arg1 arg2 arg3 & arg-rest)
Update a component's local state. Similar to Clojure(Script)'s swap!
Update a component's local state. Similar to Clojure(Script)'s swap!
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close