This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-10-22
Channels
- # announcements (4)
- # babashka (1)
- # beginners (35)
- # biff (1)
- # calva (34)
- # clj-kondo (21)
- # clojure (38)
- # clojure-europe (49)
- # clojure-norway (8)
- # clojurescript (12)
- # emacs (21)
- # events (1)
- # fulcro (16)
- # joyride (1)
- # malli (1)
- # nbb (7)
- # observability (2)
- # pathom (4)
- # polylith (6)
- # reagent (4)
- # releases (1)
- # shadow-cljs (16)
- # squint (23)
- # tools-build (7)
In my app deployed in prod I have a special url which serves index.html pointing to main.js on localhost. <div id="app"></div><script src="
This is great way to try a new frontend in a production. And even fulcro inspect is working.
Connecting shadow-cljs server is solved by changing devtools-url.
(when *localjs*
[:script "shadow.cljs.devtools.client.env.devtools_url='
But there are still hundreds 404s when loading *.maps
https://production.example.com/js/main/cljs-runtime/com.fulcrologic.rad.rendering.semantic_ui.semantic_ui_controls.js.map
So is there a similar way to load *.map files from localhost?
:asset-path
controls this, it is badly named so it isn't obvious but it accepts a full url
another option may be using https://shadow-cljs.github.io/docs/UsersGuide.html#dev-http-proxy
so you access localhost but proxy to your production server for any request that isn't available locally (ie. all non-local files/routes)
there is a config option for that https://shadow-cljs.github.io/docs/UsersGuide.html#proxy-support
I'm not sure if this is the right channel, but when I get errors I see a JS stack trace, like in the screen shot. Is there a way to get that as a cljs stack trace, with line numbers from my cljs files?
dunno. which browser is this? source maps are provided, whether your browser makes use of them shadow-cljs has no influence over
Hm, only Firefox seems to use them (not Brave or Chrome). Thanks! I'll try to find out more.