Liking cljdoc? Tell your friends :D

tinsel.core

Enlive-style templates with Hiccup.

Enlive-style templates with Hiccup.
raw docstring

accumulateclj

(accumulate & transformers)

Takes a sequence of transformers as argument and returns a transformer that applies them all in order to a node, using the output of the previous as the input to the next.

Takes a sequence of transformers as argument and returns a transformer that
applies them all in order to a node, using the output of the previous as
the input to the next.
raw docstring

append-contentcljmacro

(append-content new-content)

apply-transformclj

(apply-transform [select? transform] form)

Given a transform (a selector function and a tranformation function), applies it where the selector dictates to the form given.

Given a transform (a selector function and a tranformation function), applies
it where the selector dictates to the form given.
raw docstring

apply-transformsclj

(apply-transforms transform-list forms)

transform-list is a list of pairs of functions. The first in each pair is a selector function; it returns true if the node is one of interest. The second is the transformer function; it is applied to nodes whose selector is true. The argument forms is a list of hiccup forms to apply all the transformations to in order.

transform-list is a list of pairs of functions. The first in each pair is a
selector function; it returns true if the node is one of interest. The second
is the transformer function; it is applied to nodes whose selector is true.
The argument forms is a list of hiccup forms to apply all the transformations
to in order.
raw docstring

attr=clj

(attr= attr-name attr-value)

Returns a function that returns true if the node has the given attribute with the given value.

Returns a function that returns true if the node has the given attribute
with the given value.
raw docstring

defsnippetcljmacro

(defsnippet tmpl-name source arg-list & transforms)

deftemplatecljmacro

(deftemplate tmpl-name source arg-list & transforms)

every-selectorclj

(every-selector & selectors)

Takes any number of selectors and returns a selector that is true if all of the argument selectors are true.

Takes any number of selectors and returns a selector that is true if
all of the argument selectors are true.
raw docstring

has-attr?clj

(has-attr? attr-name)

Returns a function that returns true if the node has the given attribute (with any value). Argument can be string/keyword/symbol.

Returns a function that returns true if the node has the given attribute
(with any value). Argument can be string/keyword/symbol.
raw docstring

has-class?clj

(has-class? class)

Returns a function that returns true if the node has the given class.

Returns a function that returns true if the node has the given class.
raw docstring

hiccup-fileclj

(hiccup-file file-path)

Parse hiccup forms out of the argument.

Parse hiccup forms out of the argument.
raw docstring

html-documentclj

(html-document string-or-reader)

Parse an HTML document out of the argument given, which can be either a string containing the HTML document, or a reader for that document.

Parse an HTML document out of the argument given, which can be either a
string containing the HTML document, or a reader for that document.
raw docstring

html-fragmentclj

(html-fragment string-or-reader)

Parse an HTML fragment out of the argument given, which can be either a string containing the HTML fragment, or a reader for that fragment.

Parse an HTML fragment out of the argument given, which can be either a
string containing the HTML fragment, or a reader for that fragment.
raw docstring

id=clj

(id= id)

Returns a function that returns true if the node has id equal to id.

Returns a function that returns true if the node has id equal to id.
raw docstring

nth-child?clj

(nth-child? n)

Returns a function that returns true if the node is the nth child of its parent (and it has a parent). First element is 1, last is n.

Returns a function that returns true if the node is the nth child of
its parent (and it has a parent). First element is 1, last is n.
raw docstring

nth-last-child?clj

(nth-last-child? n)

Returns a function that returns true if the node is the nth last child of its parent (and it has a parent).

Returns a function that returns true if the node is the nth last child
of its parent (and it has a parent).
raw docstring

or-ancestorclj

(or-ancestor selector)

Takes a selector as argument and returns a selector that will match any node for which either that node or some ancestor node in the tree matches the argument selector. Returns the loc of the matching ancestor node.

Takes a selector as argument and returns a selector that will match any
node for which either that node or some ancestor node in the tree matches
the argument selector. Returns the loc of the matching ancestor node.
raw docstring

prepend-contentcljmacro

(prepend-content new-content)

selectclj

(select & selectors)

Takes any number of selectors as arguments and selects nodes that match the path down the tree specified. Returns the loc of the matched node.

Takes any number of selectors as arguments and selects nodes that match
the path down the tree specified. Returns the loc of the matched node.
raw docstring

set-attrscljmacro

(set-attrs attr-map)

set-contentcljmacro

(set-content new-content)

some-selectorclj

(some-selector & selectors)

Takes any number of selectors and returns a selector that is true if any of the argument selectors are true.

Takes any number of selectors and returns a selector that is true if
any of the argument selectors are true.
raw docstring

tag=clj

(tag= tag)

Returns a function that returns true if the node has tag equal to arg.

Returns a function that returns true if the node has tag equal to arg.
raw 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