This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-05-25
Channels
- # announcements (4)
- # babashka (13)
- # beginners (115)
- # cider (62)
- # clj-kondo (16)
- # cljdoc (4)
- # cljs-dev (5)
- # clojure (44)
- # clojure-europe (57)
- # clojure-greece (1)
- # clojure-italy (2)
- # clojure-nl (3)
- # clojure-spec (2)
- # clojure-uk (24)
- # clojurescript (58)
- # code-reviews (2)
- # community-development (6)
- # conjure (3)
- # core-async (9)
- # cursive (34)
- # datahike (3)
- # datalog (1)
- # datomic (67)
- # emacs (9)
- # events (5)
- # fulcro (9)
- # graalvm (1)
- # jobs (1)
- # lsp (24)
- # off-topic (20)
- # pathom (17)
- # polylith (11)
- # re-frame (21)
- # react (21)
- # reagent (3)
- # reitit (23)
- # releases (1)
- # remote-jobs (1)
- # ring (3)
- # sci (47)
- # tools-deps (7)
- # vim (15)
- # xtdb (4)
Iām having some trouble understanding how to write async coeffect-handlers (e.g. loading some data from a server)? Am I misunderstanding the intended purpose?
There can be no async coeffects. But there can be async effects that load the data and put it into app-db.
Is it normal that when adding or changing effect handlers, everything stops working with hot code reloading until I refresh the page?
Now I'm worried š I wonder how to debug this
Hmm, actually it's just the navigation bar that stops working... rest of the app seems to function fine
I'm pretty much doing what the re-frame template does for navigating when you make the template with the option +routes
The event still shows up in the debugger view (can't remember if this was re-frisk or the other one) but nothing seems to happen... the db doesn't get updated with the new panel
If you spend a significant amount of time on it without any progress, create a repo with a minimal reproducible example and with the exact steps I need to do to reproduce the issue, and I'll take a look.
hmm, alright. I'll see if it happens with a fresh from template app. Because pretty sure I'm dispatching the navigate event the same way as in the examples
@U2FRKM4TW here is an explanation of the steps and a repo https://github.com/Sose/brokennav/blob/main/explanation.md
I wonder if it's my system or the template or what
I tested with Chromium and Firefox and it happens in both for me
Amazing! Thanks. Should I submit an issue or a pull repo (not sure I know how) for the template?
When your code gets hot-reloaded, the routes namespace is re-evaluated, so with (def history ...)
you create a new history object each time it's re-evaluated. But you don't call start!
then, so pushy
ends up using a new history that hasn't been used in start!
.
> Should I submit an issue or a pull repo (not sure I know how) for the template? Sure! I think it makes sense. First an issue and then a PR for that issue.
should be a trivial change if I know where to find the code in the template thing š thanks again
PR merged to re-frame-template and released. Thanks for debugging/fixing the issue @U2FRKM4TW @UQDFC6V4Z :thumbsup: