plexus / chestnut

Application template for Clojure + ClojureScript web apps
Eclipse Public License 1.0
1.32k stars 99 forks source link

Compatibility fixes: --reagent and lein figwheel #248

Closed plexus closed 5 years ago

plexus commented 5 years ago

There's a bunch of existing documentation out there that starts with a lein new chestnut, and so we should try not to break existing invocations and uses. Even though --reagent is now the default, it should still be possible to specify the flag.

We should also make sure that lein figwheel continues to work. Normally we start figwheel as part of the system, but sometimes people use Chestnut only for the figwheel/clojurescript part, and in that case they might only care about running Figwheel. Since we write our compiled js to dev-target/public, we should make sure dev-target is on the classpath so the Figwheel web server can find it.

plexus commented 5 years ago

@featheredtoast could you quickly go over this to see if it looks good to you? It seems there are some Lambda Island episodes which are based on Chestnut which no longer work, which is a bit embarrassing :sweat_smile:

featheredtoast commented 5 years ago

hmm, there's an issue with dev-target in that we want that to be outside of the path, due to reloading issues with cljc. When cljs compiles, it copies over the raw cljc files as well (for sourcemapping) into the target -- which makes clj thinks it needs to reload, which leads to a broken repl experience...

We may need to look at another way for making lein figwheel work in this case.

plexus commented 5 years ago

Ok, I'll split this up so at least --reagent works again