🥷 Clojure Pro Tip 5: Hiccup Raw


Published: 2025-05-15, Last Updated: 2025-05-17

In case you don’t know it, we can use raw strings, like embedding JS code, in hiccup.

I just found out we can use raw to prevent strings from getting escaped. I used to have to define a dedicated app.js for that, which would need an extra HTTP request.

Hiccup raw in action
Hiccup raw in action

Looking back, I should’ve found this at the very beginning, as it’s just mentioned on its GitHub homepage, but somehow I missed it.


See also

comments powered by Disqus