(generate elem)
generates string html for element
(generate (tree->node [:body [:div "hello"] "world"])) => "<body>\n <div>hello</div>world\n</body>"
generates string html for element (generate (tree->node [:body [:div "hello"] "world"])) => "<body>\n <div>hello</div>world\n</body>"
(html rep)
converts either node or tree representation to a html string
(html [:body [:div "hello"] "world"]) => "<body>\n <div>hello</div>world\n</body>"
converts either node or tree representation to a html string (html [:body [:div "hello"] "world"]) => "<body>\n <div>hello</div>world\n</body>"
(html-inline rep)
emits body with no newline
(html-inline [:body [:div "hello"] "world"]) => "<body> <div>hello</div>world</body>"
emits body with no newline (html-inline [:body [:div "hello"] "world"]) => "<body> <div>hello</div>world</body>"
(inline html)
emits function without any newlines
(inline (html [:body [:div "hello"] "world"])) => "<body> <div>hello</div>world</body>"
emits function without any newlines (inline (html [:body [:div "hello"] "world"])) => "<body> <div>hello</div>world</body>"
(text _)
(node rep)
converts either a string or tree representation to a Jsoup node
(node [:body [:div "hello"] "world"]) => org.jsoup.nodes.Element
converts either a string or tree representation to a Jsoup node (node [:body [:div "hello"] "world"]) => org.jsoup.nodes.Element
converts a Jsoup node to tree
(-> (parse "<body><div>hello</div>world</body>") (node->tree)) => [:body [:div "hello"] "world"]
converts a Jsoup node to tree (-> (parse "<body><div>hello</div>world</body>") (node->tree)) => [:body [:div "hello"] "world"]
(parse s)
reads a Jsoup node from string
(parse "<body><div>hello</div>world</body>") => org.jsoup.nodes.Element
reads a Jsoup node from string (parse "<body><div>hello</div>world</body>") => org.jsoup.nodes.Element
(select-first node query)
gets the first match given selector and node
gets the first match given selector and node
(tighten html)
removes lines for elements that contain no internal elements
(tighten "<b>\nhello\n</b>") => "<b>hello</b>"
removes lines for elements that contain no internal elements (tighten "<b>\nhello\n</b>") => "<b>hello</b>"
(tree rep)
converts either a string or node representation into a tree
(tree +content+) => [:html {:id "3"} [:head [:title "First parse"]] [:body [:p "Parsed HTML into a doc."]]]
converts either a string or node representation into a tree (tree +content+) => [:html {:id "3"} [:head [:title "First parse"]] [:body [:p "Parsed HTML into a doc."]]]
(tree->node rep)
converts a tree to a Jsoup node
(tree->node [:body [:div "hello"] "world"]) => org.jsoup.nodes.Element
converts a tree to a Jsoup node (tree->node [:body [:div "hello"] "world"]) => org.jsoup.nodes.Element
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close