Fork me on GitHub

Hey, do you know why re-frame-10x isn’t picking up the changes (after opening page first time)? I’m using shadow-cljs…


after changing something in code the past changes also appearing


also re_frame.db.app_db.state is showing, that changes were applied


but re-frame-10x isn’t reflecting it in UI.


The re-frame-10x panel has to be open before you make a change. Same thing as with the Network tab in the DevTools - it won't show any previous requests, only the ones that will be issued when the DevTools panel is open.


If that's not what you're experiencing, please create a minimal reproducible example.


I was wonder if there is the way to tell 10x to be loaded before :dev/after-load is triggered


Can tell for sure, but can you try opening it in a separate window and see if that works for you? There's a button for that.


In the re-frame api docs on reg-sub, it talks about the signal function

(fn [query-vec dynamic-vec]
   [(subscribe [:a-sub])
    (subscribe [:b-sub])])
What is dynamic-vec ? I couldn’t find a definition of that in that doc? Is it the same as the third argument to subscribe as described in the API docs? > an optional 3rd argument, which is a vector of further input signals (atoms, reactions, etc), NOT values. This argument exists for historical reasons and is borderline deprecated these days.


It is a list of reactive values (ratoms, reactions, etc) that can be provided when you call subscribe. They will be dereferenced and passed in a list as the third argument to your subscription handler. In the input signal function I do not believe they are de-referenced for you. Something like this might illustrate. (I did not test, just wrote it out here)

 (fn [db [_ foo] [r1 r2]] 
  (and (= foo "foo")
       (= r1 :ratom1)
       (= r2 :ratom2))))

@(rf/subscribe [:asdf "foo"] [(r/atom :ratom1) (r/atom :ratom2)]) ;; => true


Thanks! Is it also a depreciated use case now and I can pretty much just ignore it? Or is there use cased it might be interesting to use?


I'm not sure what the official stance is, but I would treat it as deprecated since this feature isn't really documented anymore. I've personally never found a use case for it. This page has some reading you may find interesting:


No such use cases exist - IIRC subscription caching has made this feature completely unnecessary.

☝️ 1
👍 1