Liking cljdoc? Tell your friends :D

com.oakmac.cljs-util.dom

Utility functions for interacting with the DOM

Utility functions for interacting with the DOM
raw docstring

add-class!cljs

(add-class! el classname)
source

add-event!cljs

(add-event! el-or-id evt-type evt-fn)
source

append-html!cljs

(append-html! el additional-html)
source

form->valuescljs

(form->values el)

Returns the values from a DOM Form Element as a ClojureScript Map

Returns the values from a DOM Form Element as a ClojureScript Map
sourceraw docstring

get-elementcljs

(get-element arg)

Attempts to grab a single DOM element.

arg can be either:

  1. already a DOM element
  2. id of an element (ie: document.getElementById)
  3. a querySelector CSS string

Returns nil if not able to grab the element.

Attempts to grab a single DOM element.

arg can be either:
1) already a DOM element
2) id of an element (ie: document.getElementById)
3) a querySelector CSS string

Returns nil if not able to grab the element.
sourceraw docstring

get-heightcljs

(get-height el)
source

get-widthcljs

(get-width el)
source

hide-el!cljs

(hide-el! el)
source

query-selectcljs

(query-select q)
source

query-select-allcljs

(query-select-all q)
source

remove-class!cljs

(remove-class! el classname)
source

remove-element!cljs

(remove-element! el)
source

safe-prevent-defaultcljs

(safe-prevent-default js-evt)

calls preventDefault() on a JS event if possible does nothing if js-evt.preventDefault is not a function returns nil

calls preventDefault() on a JS event if possible
does nothing if js-evt.preventDefault is not a function
returns nil
sourceraw docstring

set-inner-html!cljs

(set-inner-html! el html)
source

set-style-prop!cljs

(set-style-prop! el prop value)
source

show-el!cljs

(show-el! el)
source

xy-inside-element?cljs

(xy-inside-element? el x y)
source

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

× close