Quick start issue

Decided to give Clojurescript a go while I’m evaluating different alternatives for front-end development. I seem to have hit a bit of an issue in the Quick Start. I setup the deps.edn (this is on Linux) and the folder structure is as it should be, but if I enter clj --main cljs.main --compile hello-world.core --repl from the project root directory (where the deps.edn file is), I get the following error:

Caused by: java.lang.IllegalArgumentException: Namespace hello-world.core does not exist. Please check that namespaces with dashes use underscores in the ClojureScript file name.

I’m not sure what I’m doing wrong. Any advice? Feeling a bit frustrated that I’m 2 minutes in and the intro guide doesn’t seem to work.

1 Like

Make sure your file path on disk is src/hello_world/core.cljs – note the _ in the file path corresponding to the - in the namespace – and in core.cljs, you have (ns hello-world.core ...) with a -, not _.

Both are correct and it still doesn’t seem to work.

Is this resolved ? I just followed the QuickStart docs as it and able to get it run. Put the code here:


It would help if you can make your attempt available somewhere - otherwise it’s hard to guess what went wrong

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.