This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-10-20
Channels
- # announcements (33)
- # aws (1)
- # babashka (8)
- # beginners (100)
- # calva (59)
- # clara (4)
- # clj-kondo (33)
- # cljdoc (9)
- # cljs-dev (30)
- # cljsrn (1)
- # clojure (28)
- # clojure-australia (1)
- # clojure-boston (1)
- # clojure-dev (4)
- # clojure-europe (14)
- # clojure-france (5)
- # clojure-italy (7)
- # clojure-nl (1)
- # clojure-uk (36)
- # clojurescript (13)
- # clojureverse-ops (6)
- # conjure (2)
- # cursive (2)
- # datahike (11)
- # datalevin (1)
- # datomic (106)
- # graphql (3)
- # helix (10)
- # holy-lambda (24)
- # kaocha (2)
- # lambdaisland (3)
- # lsp (199)
- # malli (35)
- # off-topic (16)
- # pathom (7)
- # polylith (38)
- # portal (16)
- # quil (2)
- # re-frame (18)
- # reagent (57)
- # shadow-cljs (11)
- # testing (3)
- # xtdb (9)
Is a re-frame subscription supposed to see all atom values over time, necessarily? Or can it skip some?
I see. That completely explains my issue then. Is there any way to get around this?
To render while you rendering? :) Not really.
But you can split updates into multiple operations and use :flush-dom
event metadata.
Okay, I see, I'll look it up, thanks.
Different problem, same solution: https://github.com/day8/re-frame/blob/master/docs/Solve-the-CPU-hog-problem.md
I'm not sure how this is related
I don't have any intesive work to do, I'm just trying to dispatch-sync a "http request is in progress" marker in the db to avoid a second request to run before the first one has completed
and as it turns out, dispatch-sync is not enough for that, the db gets updated, the souscription caches don't
maybe the issue is the 16ms thingy, tho
probably https://github.com/day8/re-frame/blob/master/docs/flow-mechanics.md#truth-interlude related
yep, flush was what I needed!
Are you per chance trying to do that dispatch within the event that is sending off the http request?
If so, please just write a function that will update your db with the loading flag to true and have the http request be in an fx vector
That will be far easier to reason about and is actually atomic without relying on things like flush
I second @U3JH98J4R just set a loading flag to true from the event that dispatches the http request