Re:Nazca – New GUI for the Web
by Eikon on Wednesday November 03, 2021 @09:15AM
(#29094131)
From the example:
Seems pretty awful to me...
[ Parent
| on HN ]
In Clojure (hiccup), the idea is similar (lists for HTML) but with a nicer syntax. Comparing it, how does this seem as an alternative?
[:html
[:head [:title "A simple Hello world example"]]
[:body [:div "Hello World"]]]
It's simply lists inside lists, with keywords (:html) being converted to HTML elements, and second (and the rest) item/s being children of whatever came as the first keyword in the list.Hard to compete with any lisp at generating html - html is basically just a verbose lisp.
I was sitting here thinking why doesn't the author just use reagent? so much nicer and you aren't using yet another DSL