Some quick feedback as I play with figwheel.main - Seems odd to me that I can't refer to a filename for -b. Stated another way it's odd that there's a requirement that build option files end in .cljs.edn. I see the superficial benefit of simpler/shorter invocations but cost of unnecessary opaqueness and forcing filename conventions seems. Perhaps that boils down to "it's easy but not simple".
(but know that I love figwheel and appreciate all your hard work)
There's a long explaination as to why this works the way it does
it's mostly because a build files purpose is to create an id
. This id
has a lot of value in to the build process in terms of isolating it from other builds. The id
informs where output files go, it informs which REPL connects to which open tab, it is a handle that is used in the scripting api. A concise id is a semantic handle that is much better than I the more general path for all of these uses. I also want to differentiate the -b
option from the -co
option and make it similar to how folks are accustomed to using figwheel and cljsbuild.
hello
I'm using figwheel-sidecar.repl-api/start-figwheel!
and [figwheel-sidecar "0.5.16"]
I tryied to add :ring-handler
next to compiler
and inside figwheel
map, and both fail (f/start-figwheel! {:builds [{:figwheel {} :compiler {}}]})
Where should I add it?
Next to compiler:
:ring-handler server.core/index-handler
^---- The key :ring-handler should probably be :warning-handlers
it needs to go in :figwheel-options
Exception Unable to resolve spec: :figwheel-sidecar.schemas.config/cljs-build-fn strictly-specking-standalone.spec/the-spec (spec.clj:143)
that sounds like a different problem entirely
are you using Clojure 0.1.9?
oh
1.10.0-alpha6
That is because I'm still using figwheel-sidecar
, not?
I will try to move to figwheel-main
I have no idea what is causing that error
it makes no sense
I'd start again fresh
Connecting to local nREPL server...
Clojure 1.10.0-alpha6
nREPL server started on port 40991 on host 127.0.0.1 - <nrepl://127.0.0.1:40991>
(require 'figwheel-sidecar.schemas.config)
=> nil
(user/start)
Exception Unable to resolve spec: :figwheel-sidecar.schemas.config/cljs-build-fn strictly-specking-standalone.spec/the-spec (spec.clj:143)
(require '[clojure.spec.alpha :as s])
=> nil
(s/describe :figwheel-sidecar.schemas.config/cljs-build-fn)
Exception Unable to resolve spec: :figwheel-sidecar.schemas.config/cljs-build-fn clojure.spec.alpha/reg-resolve! (alpha.clj:69)
(strictly-specking-standalone.spec/describe :figwheel-sidecar.schemas.config/cljs-build-fn)
Exception Unable to resolve spec: :figwheel-sidecar.schemas.config/cljs-build-fn strictly-specking-standalone.spec/the-spec (spec.clj:143)
yeah that wont work because figwheel-sidecar is using a vendored version of spec
There is a (strictly-specking-standalone.spec/describe :figwheel-sidecar.schemas.config/cljs-build-fn)
too
The project is here:
https://github.com/souenzzo/my-next-stack/blob/master/dev/user.clj#L56
With a :figwheel-options {:ring-handler 'server.core/index-handler}
on this line
(this handler also not commited)