This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-03-29
Channels
- # announcements (4)
- # architecture (25)
- # babashka (23)
- # beginners (56)
- # boot (4)
- # calva (1)
- # cider (1)
- # cljs-dev (15)
- # clojure (135)
- # clojure-europe (4)
- # clojure-nl (21)
- # clojure-uk (61)
- # clojurescript (47)
- # community-development (4)
- # cryogen (11)
- # cursive (11)
- # data-science (11)
- # fulcro (25)
- # funcool (5)
- # graalvm (1)
- # graphql (4)
- # kaocha (4)
- # lambdaisland (20)
- # lumo (7)
- # meander (14)
- # off-topic (9)
- # pathom (2)
- # portkey (1)
- # re-frame (5)
- # reagent (53)
- # reitit (2)
- # ring (3)
- # shadow-cljs (32)
- # spacemacs (4)
- # sql (34)
- # testing (1)
- # tools-deps (3)
Hey all. I wrote a watcher that looks at EDN file for changes. Once it finds a change it'll aggregate these files and output them into a CLJS file. I wanted to be able to write .edn format without having to use HTTP requests to get them. https://github.com/kwrooijen/cljs-auto
Any feedback would be appreciated 🙂 Maybe I'm not even solving this issue the right way
It also allows you to watch for newly created CLJS files, and add them in the :require
option for the generated namespace. This is useful if you're using integrant in Clojurescript, since it doesn't support dynamic requires. Integrant has a feature to automatically require namespaces, but that isn't supported in CLJS
@kevin.van.rooijen The way people solve including files from the filesystem inside CLJS is usually with a macro (which is executed at compile time by the JVM)
I wonder if I could use macros to automatically add require statements to the namespace
Well it's not a big issue. Just a bit annoying having to require every module purely to access the multimethods
@kevin.van.rooijen What cannot be solved with macros can be solved with a simple scripts and code generation outside of the normal dev workflow