This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2015-09-05
Channels
- # beginners (8)
- # boot (6)
- # cider (9)
- # clojure (43)
- # clojure-art (1)
- # clojure-australia (3)
- # clojure-berlin (1)
- # clojure-japan (4)
- # clojure-russia (13)
- # clojurescript (72)
- # core-matrix (1)
- # cursive (2)
- # datomic (1)
- # events (1)
- # hoplon (312)
- # jobs (1)
- # ldnclj (5)
- # off-topic (52)
- # overtone (2)
- # re-frame (5)
- # reagent (6)
- # testing (1)
@vastor: Selmer is like Jinja2/Django templates, Enlive is HTML represented as Clojure vectors (`[:div [:a {:href “/“} “click me”]]`)
@jeffmk isn’t it Hiccup that is html as vectors? Haven’t looked at these for months but from memory Selmer is a templating library that does placemarker replacement in html templates and Enlive actually pattern matches on selectors and ids in static HTML files and manipulates it to produce dynamic pages.
Pragmatically it means Selmer templates need markup to indicate the dynamic elements whereas Enlive is raw HTML with no markup (unless you want it).
@agile_geek @vastor Apologies, I had just woken and not had any caffeine 😐
Looking at the github pages is useful to see context: https://github.com/cgrand/enlive https://github.com/yogthos/Selmer
@jeffmk no problem. The way I think about the difference is that enlive lets designers work completely in static HTML without polluting it with markup. However, I’m not sure this is a big advantage as enlive is more sensitive to changes in Selectors/Ids that a designer would not think would have a side effect whereas markup in the HTML is explicit. Of course, enlive can do mark up too and gives a lot of flexibility to manipulate the shape of the page dynamically.