Liking cljdoc? Tell your friends :D

hoplon.core


$commentcljs

source

$textcljs

source

-->cljs

source

->hoploncljs

(->hoplon elem)
source

<!--cljs

source

acljs

source

abbrcljs

source

add-attributes!cljs

(add-attributes! this attr)
source

add-children!cljs

(add-children! this kids)
source

add-initfn!cljs

(add-initfn! f)

Executes a function once the window load event is fired.

Executes a function once the window load event is fired.
sourceraw docstring

addresscljs

source

append-child!cljs

(append-child! this child)
source

areacljs

source

articlecljs

source

asidecljs

source

attribute?cljs

(attribute? this)
source

audiocljs

source

bcljs

source

basecljs

source

bdicljs

source

bdocljs

source

blockquotecljs

source

bodycljs

Updates and returns the document's body element in place.

Updates and returns the document's `body` element in place.
sourceraw docstring

brcljs

source

buttoncljs

source

canvascljs

source

captioncljs

source

case-tplclj/smacro

(case-tpl expr & clauses)

Template. Accepts an expr cell and a number of clauses and returns a cell with the value produced by the matching clause:

(case-tpl expr :a (span "A") :b (span "B") (span "Default"))

Template. Accepts an `expr` cell and a number of `clauses` and returns a
cell with the value produced by the matching clause:

  (case-tpl expr
    :a (span "A")
    :b (span "B")
    (span "Default"))

sourceraw docstring

citecljs

source

codecljs

source

colcljs

source

colgroupcljs

source

cond-tplclj/smacro

(cond-tpl & clauses)

Template. Accepts a number of clauses cell-template pairs and returns a cell with the value produced by the matching clause:

(cond-tpl clause-a (span "A") clause-b (span "B") :else (span "Default"))

Template. Accepts a number of `clauses` cell-template pairs and returns a
cell with the value produced by the matching clause:

  (cond-tpl
    clause-a (span "A")
    clause-b (span "B")
    :else    (span "Default"))
sourceraw docstring

datacljs

source

datalistcljs

source

ddcljs

source

defattrclj/smacro

(defattr name & forms)

Defines an attribute function.

An element attribute is a function given three arguments:

  • elem - the target DOM Element containing the attribute
  • key - the attribute keyword or symbol
  • value - the attribute value

The attribute function is called whenever the value argument changes.

Defines an attribute function.

An element attribute is a function given three arguments:

  * `elem` - the target DOM Element containing the attribute
  * `key` - the attribute keyword or symbol
  * `value` - the attribute value

The attribute function is called whenever the value argument changes.
sourceraw docstring

defelemclj/smacro

(defelem name & forms)

Defines an element function.

An element function creates a DOM Element (parent) given two arguments:

  • attrs - a number of key-value pairs for attributes and their values
  • kids - a sequence of DOM Elements to be appended/used inside

The returned DOM Element is itself a function which can accept more attributes and child elements.

Defines an element function.

An element function creates a DOM Element (parent) given two arguments:

  * `attrs` - a number of key-value pairs for attributes and their values
  * `kids` - a sequence of DOM Elements to be appended/used inside

The returned DOM Element is itself a function which can accept more
attributes and child elements.
sourceraw docstring

delcljs

source

detailscljs

source

dfncljs

source

dialogcljs

source

divcljs

source

dlcljs

source

do!cljsmultimethod

source

do-watchcljs

(do-watch ref f)
(do-watch ref init f)

Adds f as a watcher to ref and evaluates (f init @ref) once. The watcher f is a function of two arguments: the previous and next values. If init is not provided the default (nil) will be used.

Adds f as a watcher to ref and evaluates (f init @ref) once. The watcher
f is a function of two arguments: the previous and next values. If init is
not provided the default (nil) will be used.
sourceraw docstring

dtcljs

source

elemclj/smacro

(elem bind & body)

Create an anonymous custom element.

Create an anonymous custom element.
sourceraw docstring

elem!cljsmultimethod

source

element?cljs

(element? this)

Returns true if elem is a managed element. Managed elements have their children managed by Hoplon and implement the IHoplonElement protocol.

Returns true if elem is a managed element. Managed elements have
their children managed by Hoplon and implement the IHoplonElement protocol.
sourceraw docstring

emcljs

source

embedcljs

source

fieldsetcljs

source

figcaptioncljs

source

figurecljs

source

source

for-tplclj/smacro

(for-tpl [bindings items] body)

Template. Accepts a cell-binding and returns a cell containing a sequence of elements:

(for-tpl [x xs] (span x))

Template. Accepts a cell-binding and returns a cell containing a sequence of
elements:

  (for-tpl [x xs] (span x))
sourceraw docstring

formcljs

source

h1cljs

source

h2cljs

source

h3cljs

source

h4cljs

source

h5cljs

source

h6cljs

source

Updates and returns the document's head element in place.

Updates and returns the document's `head` element in place.
sourceraw docstring

source

hgroupcljs

source

hl!cljsmultimethod

source

hoplonify!cljs

(hoplonify! elem)
source

hrcljs

source

htmlcljs

(html & args)
source

html-mapcljs

source

html-metacljs

source

html-objectcljs

source

html-timecljs

source

html-varcljs

source

icljs

source

if-tplclj/smacro

(if-tpl predicate consequent & [alternative])

Template. Accepts a predicate cell and returns a cell containing either the element produced by consequent or alternative, depending on the value of the predicate:

(if-tpl predicate (span "True") (span "False"))

Template. Accepts a `predicate` cell and returns a cell containing either
the element produced by `consequent` or `alternative`, depending on the value
of the predicate:

  (if-tpl predicate (span "True") (span "False"))
sourceraw docstring

iframecljs

source

IHoplonAttributecljsprotocol

-attribute!cljs

(-attribute! this elem value)
source

IHoplonElementcljsprotocol

-append-child!cljs

(-append-child! this child)

Appends child to this for the case of this being a managed element.

Appends `child` to `this` for the case of `this` being a managed element.

-hoplon-kidscljs

(-hoplon-kids this)

Returns the hoplon managed kids atom, or creates it if missing.

Returns the hoplon managed kids atom, or creates it if missing.

-insert-before!cljs

(-insert-before! this new existing)

Inserts existing before new in this for the case of this being a managed element.

Inserts `existing` before `new` in `this` for the case of `this` being a managed element.

-remove-child!cljs

(-remove-child! this child)

Removes child from this for the case of this being a managed element.

Removes `child` from `this` for the case of `this` being a managed element.

-replace-child!cljs

(-replace-child! this new existing)

Replaces existing with new in this for the case of this being a managed element.

Replaces `existing` with `new` in `this` for the case of `this` being a managed element.

-set-attributes!cljs

(-set-attributes! this kvs)

Sets attributes on a managed element using native functionality.

Sets attributes on a managed element using native functionality.

-set-styles!cljs

(-set-styles! this kvs)

Sets styles on a managed element using native functionality.

Sets styles on a managed element using native functionality.
source

IHoplonNodecljsprotocol

-nodecljs

(-node this)
source

imgcljs

source

inputcljs

source

inscljs

source

insert-before!cljs

(insert-before! this new existing)
source

invoke!cljs

(invoke! this & args)
source

kbdcljs

source

keygencljs

source

kw-dispatchercljs

(kw-dispatcher elem key value)

A multi-method dispatch function.

Will dispatch against three arguments:

  • elem - the target DOM Element containing the attribute
  • key - the attribute keyword
  • value - the attribute value

The kw-dispatcher will attempt to dispatch agains the key argument.

ex. when key is :namespace/key will dispatch on :namespace/key

A multi-method dispatch function.

Will dispatch against three arguments:

  * `elem`  - the target DOM Element containing the attribute
  * `key`   - the attribute keyword
  * `value` - the attribute value

The kw-dispatcher will attempt to dispatch agains the key argument.

ex. when key is `:namespace/key` will dispatch on `:namespace/key`
sourceraw docstring

labelcljs

source

legendcljs

source

licljs

source

source

loop-tplclj/smacro

(loop-tpl & args)

Template. Works identically to for-tpl, only expects a :bindings attribute to accomodate the HTML HLisp representation:

(loop-tpl :bindings [x xs] ...)

Template. Works identically to `for-tpl`, only expects a `:bindings`
attribute to accomodate the HTML HLisp representation:

  (loop-tpl :bindings [x xs] ...)
sourceraw docstring

loop-tpl*cljs

(loop-tpl* items tpl)

Given a cell items containing a seqable collection, constructs a cell that works like a fill vector. The template tpl is a function of one argument: the formula cell containing the ith item in items. The tpl function is called once (and only once) for each index in items. When the items collection shrinks the DOM element created by the template is not destroyed--it is only removed from the DOM and cached. When the items collection grows again those cached elements will be reinserted into the DOM at their original index.

Given a cell items containing a seqable collection, constructs a cell that
works like a fill vector. The template `tpl` is a function of one argument: the
formula cell containing the ith item in items. The tpl function is called
once (and only once) for each index in items. When the items collection
shrinks the DOM element created by the template is not destroyed--it is only
removed from the DOM and cached. When the items collection grows again those
cached elements will be reinserted into the DOM at their original index.
sourceraw docstring

maincljs

source

markcljs

source

source

source

metercljs

source

multicolcljs

source

native-node?cljs

(native-node? node)
source

native?cljs

(native? elem)

Returns true if elem is a native element. Native elements' children are not managed by Hoplon, and have not been extended with IHoplonElement.

Returns true if elem is a native element. Native elements' children
are not managed by Hoplon, and have not been extended with IHoplonElement.
sourceraw docstring

source

node?cljs

(node? this)
source

noframescljs

source

normalize-classcljs

(normalize-class kvs)

Class normalization for attribute providers. Converts from strings and sequences to hashmaps.

Class normalization for attribute providers. Converts from strings and
sequences to hashmaps.
sourceraw docstring

noscriptcljs

source

ns-dispatchercljs

(ns-dispatcher elem key value)

A multi-method dispatch function.

Will dispatch against three arguments:

  • elem - the target DOM Element containing the attribute
  • key - the attribute keyword
  • value - the attribute value

The ns-dispatcher will attempt to dispatch agains the key namespace or key.

ex. when key is :namespace/key will dispatch on :namespace/default otherwise :namespace/key

A multi-method dispatch function.

Will dispatch against three arguments:

  * `elem`  - the target DOM Element containing the attribute
  * `key`   - the attribute keyword
  * `value` - the attribute value

The ns-dispatcher will attempt to dispatch agains the key namespace or key.

ex. when key is `:namespace/key` will dispatch on `:namespace/default` otherwise `:namespace/key`
sourceraw docstring

olcljs

source

on!cljsmultimethod

source

optgroupcljs

source

optioncljs

source

outputcljs

source

pcljs

source

paramcljs

source

parse-argscljs

(parse-args args)

Parses a sequence of element arguments into attributes and children.

Parses a sequence of element arguments into attributes and children.
sourceraw docstring

picturecljs

source

precljs

source

prerendering?cljs

Is the application running in a prerendering container (eg. PhantomJS via the prerender task)?

Is the application running in a prerendering container (eg. PhantomJS via
the prerender task)?
sourceraw docstring

progresscljs

source

qcljs

source

remove-child!cljs

(remove-child! this child)
source

replace-child!cljs

(replace-child! this new existing)
source

rpcljs

source

rtcljs

source

rtccljs

source

rubycljs

source

scljs

source

sampcljs

source

scriptcljs

source

sectioncljs

source

selectcljs

source

set-attributes!cljs

(set-attributes! this kvs)
(set-attributes! this k v & kvs)
source

set-styles!cljs

(set-styles! this kvs)
(set-styles! this k v & kvs)
source

shadowcljs

source

smallcljs

source

sourcecljs

source

spancljs

source

spec!cljs

(spec!)
source

splicedcljs

source

strongcljs

source

stylecljs

source

subcljs

source

summarycljs

source

supcljs

source

tablecljs

source

tbodycljs

source

tdcljs

source

templatecljs

source

terpol8clj

(terpol8 s)
source

textclj/smacro

(text form)

Creates a DOM Text node and binds its text content to a formula created via string interpolation, so the Text node updates with the formula.

Creates a DOM Text node and binds its text content to a formula created via
string interpolation, so the Text node updates with the formula.
sourceraw docstring

textareacljs

source

tfootcljs

source

thcljs

source

theadcljs

source

timeoutcljs

(timeout f)
(timeout f t)

Executes a fuction after a delay, if no delay is passed, 0 is used as a default.

Executes a fuction after a delay, if no delay is passed, 0 is used as a default.
sourceraw docstring

titlecljs

source

trcljs

source

trackcljs

source

ucljs

source

ulcljs

source

videocljs

source

wbrcljs

source

when-domcljs

(when-dom this f)

Executes a function once an element has been attached to the DOM.

Executes a function once an element has been attached to the DOM.
sourceraw docstring

when-tplclj/smacro

(when-tpl predicate & body)

Template. Accepts a predicate cell and returns a cell containing either the element produced by consequent or nothing, depending on the value of the predicate:

(when-tpl predicate (span "Value"))

Template. Accepts a `predicate` cell and returns a cell containing either
the element produced by `consequent` or nothing, depending on the value of
the predicate:

  (when-tpl predicate (span "Value"))
sourceraw docstring

with-animation-frameclj/smacro

(with-animation-frame & body)

Evaluates the body before the next browser repaint as requestAnimationFrame.

Evaluates the body before the next browser repaint as requestAnimationFrame.
sourceraw docstring

with-domclj/smacro

(with-dom elem & body)

Evaluates the body after elem has been inserted into the DOM.

Evaluates the body after elem has been inserted into the DOM.
sourceraw docstring

with-init!clj/smacro

(with-init! & body)

Evaluates the body after Hoplon has completed constructing the page.

Evaluates the body after Hoplon has completed constructing the page.
sourceraw docstring

with-intervalclj/smacro

(with-interval msec & body)

Evaluates the body every msec milliseconds, asynchronously. Returns the interval ID which can be used to cancel the operation (see js/clearInterval).

Evaluates the body every msec milliseconds, asynchronously. Returns the
interval ID which can be used to cancel the operation (see js/clearInterval).
sourceraw docstring

with-timeoutclj/smacro

(with-timeout msec & body)

Evaluates the body after msec milliseconds, asynchronously. Returns the timeout ID which can be used to cancel the operation (see js/clearTimeout).

Evaluates the body after msec milliseconds, asynchronously. Returns the
timeout ID which can be used to cancel the operation (see js/clearTimeout).
sourceraw docstring

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

× close