This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-05-02
Channels
- # announcements (12)
- # babashka (7)
- # babashka-sci-dev (46)
- # beginners (35)
- # biff (1)
- # calva (4)
- # cider (22)
- # clj-kondo (48)
- # clj-on-windows (4)
- # clojure (132)
- # clojure-europe (161)
- # clojure-germany (1)
- # clojure-nl (2)
- # clojure-uk (5)
- # clojurescript (39)
- # conjure (10)
- # core-typed (1)
- # cursive (48)
- # datalevin (6)
- # datascript (12)
- # datomic (9)
- # emacs (5)
- # events (1)
- # figwheel-main (2)
- # honeysql (7)
- # hyperfiddle (35)
- # improve-getting-started (8)
- # introduce-yourself (4)
- # london-clojurians (1)
- # off-topic (20)
- # podcasts-discuss (1)
- # re-frame (45)
- # reitit (5)
- # releases (2)
- # rum (7)
- # shadow-cljs (20)
- # spacemacs (4)
- # tools-build (58)
- # tools-deps (19)
- # xtdb (56)
meh, that is severly outdated by now. would probably be best served by a custom :target
build on top of :target :esm
or so https://clojureverse.org/t/generating-es-modules-browser-deno/6116
oh, how would I be able to export my pages fn without having to specify all of them in :exports
config? :thinking_face:
can't say. custom :target
could maybe generate it somehow. haven't looked at next.js since making that repo. no clue what it looks like nowadays
Is there a doc for using custom :target
? 🙏 also I'm targeting Remix not Next.js but both are file-based routing & expect some default exports per page file
no docs no. only reference is all the default targets https://github.com/thheller/shadow-cljs/tree/master/src/main/shadow/build/targets

hi guys, I'm trying to start a little project with shadow-clj / re-frame / emacs / cider with the re-frame template, https://github.com/day8/re-frame-template with lein. Opening the repl from within Emacs (C-c M-j) works ok, but when invoking any function, in different namespaces, I keep getting the same error reported:
Syntax error compiling at (*cider-repl flexiana/scrambler-fe:localhost:8777(clj)*:50:20).
Unable to resolve symbol: init in this context
and no Clojure / REPL related Emacs shortcut works, i.e. C-c C-k to compile and load current buffer, or C-c C-z to jump straight into REPL.I tried the same with the front-end / SPA module of the following little Clojure fullstack project I've taking as reference: https://github.com/lagenorhynque/clj-rest-api-and-cljs-spa-example, SPA: https://github.com/lagenorhynque/clj-rest-api-and-cljs-spa-example/tree/master/todo-app, but in that other context, I keep getting exactly the same issues described above.
Futhermore, as I start up the SPA from CLI as explained in its README:
$ npm install
$ npx shadow-cljs watch app
the SPA works well, but when started up by starting up the REPL from Emacs (C-c M-j), the SPA runs, but reporting the following warning:
shadow-cljs - Stale Output! Your loaded JS was not produced by the running shadow-clj instance. Is the watch for this build running?
the stale error you likely get because you have 2 separate shadow-cljs instances running for the project at the same time. interfering with each other. when you have the watch
running separately you need to "connect" in cider, not "jack-in".
@lmrosso you are in the Clojure REPL. that needs to be switched to CLJS first. can't say how to do that in emacs. don't know how current this is https://shadow-cljs.github.io/docs/UsersGuide.html#cider
hi @U05224H0W, thanks for such a quick reply, let me take a look...
hi @U05224H0W, yes, that was one of the very few docs I was able to find out and, as far as I understand, I've taken into account in this config
I cannot comment on any cider related issues. I don't use emacs so I really do not know. all I can see from the screenshots is that you are in a Clojure REPL
as far as shadow-cljs is concerned you switch that via evaling (shadow/repl :your-build-id-here)
asking in cider channel as well, but no reply there yet, thanks !