Closed maikelvallinga closed 10 months ago
I have a similar problem. My app dispatches :initialize-db
on startup, but that is not shown in re-frame until I pop out. Then it suddenly appears.
I cannot reproduce this issue in the example todomvc app, although the last comment on not rendering the first event on startup sounds suspiciously similar to #263
This is happening to me as well. I tried in Chrome and Brave (Chromium based).
Edit: I realized the issue doesn't happen if I use dispatch
instead of dispatch-sync
. Related: https://github.com/day8/re-frame-10x/issues/154 (I found this through the linked issue, #302). I'm just mentioning for anyone else reading this.
@MawiraIke are you able to reproduce ?
Yes @superstructor I can reproduce this issue in a new repo with only the initialize-db
event. For example, I can reproduce it when I create a new re-frame project with lein new re-frame
and add re-com
and 10x
. I also can't reproduce the issue in the todomvc app as you mentioned.
Fair to note that @bpringe solution fixes this problem. That is using dispatch
instead of dispatch-sync
shows the events and db when the page loads. I think this delay might be related to dispatch-sync
. Hovering the mouse on some components (like the v-box drag-bar for example) also seems to make the db catch up with the latest event.
dispatch-sync
problem is solved for #263 and #151.
I'm running the repro on the same lein template, but I don't see the original behavior reported by @maikelvallinga regarding the popout window. Looking at the code, there's nothing explicitly happening with the popout window to start or stop trace.
A problem does remain, but it's more of a feature, I think: trace doesn't run unless the panel is open.
I've added a new setting to control this. Now, you can choose for 10x to trace your app:
When i open the 10x window it does not show any content except buttons. So i am not able to see the app-db for example.
When i pop out the screen the content is displaying correctly and i can see the app-db. Problem occurs within Safari and Chrome.
Example with just the 10x window open:
Example when i pop out the window: