re-frame

https://github.com/Day8/re-frame/blob/master/docs/README.md https://github.com/Day8/re-frame/blob/master/docs/External-Resources.md
Gleb Posobin 2020-11-24T04:35:20.370200Z

@danielostling Check the requests tab in the web inspector.

1👍
Gleb Posobin 2020-11-24T04:35:52.370800Z

And also the console.

Daniel Östling 2020-11-24T06:38:22.371Z

Naturally, it was CORS. Thanks 🙂

Jazzer 2020-11-24T19:55:13.380400Z

Hi everyone, new here and fairly new to re-frame. My question that has brought me here is “is there such a thing as too many subscriptions?”. I’m building up an app where one key within app-db has about 15 subkeys. Each of the 15 is involved in a different component. Am I better off with 1 subscription to the parent and extracting the subkeys, or am I better off registering the 15 as second level subscriptions? Or is there another option I’m not seeing? 1 subscription seems like I’d be re-rendering a load of components unnecessarily. 16 subscriptions feel like a lot of boilerplate (albeit succinct boilerplate - yay cljs!)

p-himik 2020-11-24T20:15:33.380500Z

If those are really simple keys and you get all your subs values via simple get, then performance-wise there should be no noticeable difference. Design-wise - depends on your overall approach to the development. Subs are like getters in this case.

Jose Varela 2020-11-24T21:37:31.381Z

@genekim worked on this a few months ago, he may have a few links

Jose Varela 2020-11-24T21:38:05.381200Z

https://github.com/realgenekim/re-frame-event-graph

2020-11-24T22:09:46.381600Z

the DOM is sloooooooooow. you can run a lot of cheap subs to save a single DOM call, let alone a re-render.

2020-11-24T22:10:53.381800Z

on the other hand, if say some 6 subs always update together, there's no real benefit to splitting them up vs. 1 sub.