Api providing several tools to use inside or outside of prose document.
Api providing several tools to use inside or outside of prose document.
(<> & content)
Fragment tag whose content is meant to be spliced into its parent's content.
Fragment tag whose content is meant to be spliced into its parent's content.
(conform-or-throw spec v)
Conforms the value v
using the spec spec
and throws an ex-info
if v
is invalid.
Conforms the value `v` using the spec `spec` and throws an `ex-info` if `v` is invalid.
(def-s & args)
Same as def
except that it returns and empty string.
Same as `def` except that it returns and empty string.
(def-xml-tag name docstring? keyword-name?)
(def-xml-tag & args)
Helper in making functions that construct tags.
Args:
name
: name of the functiondocstring?
: a docstring for the functionkeyword-name?
: the actual name of the tag, defaults to the keyword version of name
Helper in making functions that construct tags. Args: - `name`: name of the function - `docstring?`: a docstring for the function - `keyword-name?`: the actual name of the tag, defaults to the keyword version of `name`
(defmacro-s & args)
Same as defmacro
except that it returns and empty string.
Same as `defmacro` except that it returns and empty string.
(defn-s & args)
Same as defn
except that it returns and empty string.
Same as `defn` except that it returns and empty string.
(eval-doc & args)
Eval a document using the function given by get-eval-doc
.
Eval a document using the function given by [[get-eval-doc]].
(get-env)
(get-env k)
Get the evaluation environment or the value for one of its keys.
Get the evaluation environment or the value for one of its keys.
(get-eval-doc)
Get the eval-forms function from the evaluation environment.
Get the eval-forms function from the evaluation environment.
(get-input)
Get the input value from the evaluation environment.
Get the input value from the evaluation environment.
(get-read-doc)
Get the reading function from the evaluation environment.
Get the reading function from the evaluation environment.
(get-slurp-doc)
Get the slurping function from the evaluation environment.
Get the slurping function from the evaluation environment.
(insert-doc path)
Insert the slurped and read content of another document.
Insert the slurped and read content of another document.
(read-doc & args)
Read a string using the function given by get-read-doc
.
Read a string using the function given by [[get-read-doc]].
(require-doc path)
Insert the slurped, read and evaluated content of another document.
Insert the slurped, read and evaluated content of another document.
(slurp-doc & args)
Slurp a document using the function given by get-slurp-doc
.
Slurp a document using the function given by [[get-slurp-doc]].
(special? x)
Determine if x
is a special tag.
Determine if `x` is a special tag.
(tag-type x)
Returns the type of a tag x
or nil isn't a map or doesn't have a type.
Returns the type of a tag `x` or nil isn't a map or doesn't have a type.
(tag? x)
Determine if x
is a normal tag.
Determine if `x` is a normal tag.
(xml-tag name attrs? & content)
(xml-tag & args)
Constructor of normal tags.
args:
name
: a keyword giving the tag his name (:div, :my-tag, etc...)attrs
: a map of attributescontent
: the content of the tag, strings, other (special)tags or sequences of both.Returns a map similar to:
{:type :tag
:tag name
:attrs attrs?
:content content}
Constructor of normal tags. args: - `name`: a keyword giving the tag his name (:div, :my-tag, etc...) - `attrs`: a map of attributes - `content`: the content of the tag, strings, other (special)tags or sequences of both. Returns a map similar to: ```clojure {:type :tag :tag name :attrs attrs? :content content} ```
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close