1
votes

I can't seem to get Garden to work with ClojureScript. Is there an incantation to perform? The docs don't mention clojurescript at all, just clojure... but clojurescript would be preferred.

Also, this guy mentioned it working with clojurescript:

Is there a lib for manipulating CSS on the client side in Clojurescript?

Is this true, or is he a dirty, rotten liar? ;)

1
What did you try, what errors do you get?schaueho

1 Answers

2
votes

The repo indicates it works with ClojureScript and CLJX files are present.

I just tried it with ClojureScript 0.0-2511 by putting [garden "1.2.5"] in :dependencies of my project.clj, and in one of my namespaces added a :require for [garden.core :refer [css]], and in the ClojureScript REPL, things appear to work:

(css [:body {:font-size "16px"}])
=> "body {\n  font-size: 16px;\n}"
(css [:h1 :h2 {:font-weight "none"}])
=> "h1, h2 {\n  font-weight: none;\n}"