blob: b97d5f238358cf88a92d08c36dc83e26fd24afa9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
(ns dompa.core
(:require
[dompa.coordinates :refer [html->coordinates]]
[dompa.nodes :refer [coordinates->nodes]]))
(defn html->nodes [html]
(let [coordinates (html->coordinates html)
nodes (coordinates->nodes html coordinates)]
nodes))
(comment
(html->coordinates "<div>hello<span>asd</span><strong>asdasdadad<img></strong></div>hello some text<div>another root element</div>")
(html->nodes "<div>hello<span>asd</span><strong>asdasdadad</strong></div>"))
|