I'm working to learn Clojure and Clojurescript; currently going through the book Living Clojure.
I'm having trouble getting ClojureScript to compile ... I just put up the example as specified in the book:
(ns cheshire-cat.core)
(defn ^:export init []
(js/alert "hi"))
I tried the book suggestion to run the compiler
lein cljsbuild auto
But I get this error:
Compiling ClojureScript.
Syntax error macroexpanding clojure.core/ns at (cljsbuild/crossover.clj:1:1).
import - failed: #{:refer-clojure} at: [:ns-clauses :refer-clojure :clause] spec: :clojure.core.specs.alpha/ns-refer-clojure
import - failed: #{:require} at: [:ns-clauses :require :clause] spec: :clojure.core.specs.alpha/ns-require
import - failed: #{:import} at: [:ns-clauses :import :clause] spec: :clojure.core.specs.alpha/ns-import
import - failed: #{:use} at: [:ns-clauses :use :clause] spec: :clojure.core.specs.alpha/ns-use
import - failed: #{:refer} at: [:ns-clauses :refer :clause] spec: :clojure.core.specs.alpha/ns-refer
import - failed: #{:load} at: [:ns-clauses :load :clause] spec: :clojure.core.specs.alpha/ns-load
import - failed: #{:gen-class} at: [:ns-clauses :gen-class :clause] spec: :clojure.core.specs.alpha/ns-gen-class
Full report at:
/tmp/clojure-3119149998558661227.edn
Help please? I've been working with Clojure for a few weeks but just starting ClojureScript.
crossover.clj, but the file that you show should besrc/cheshire_cat/core.cljs