@gardnervickers no, om/computed
exists (partly) because of pathopt
it just lets Om memoize the computed stuff so that targeted re-render is possible with just a query against the db (and not a parent refresh)
and yes, the root component won’t update if the pathopt route is taken, and as such the computed data from the parent won’t update either (since it won’t run).
@liminal18 Also have a look at https://fulcrologic.github.io/fulcro/. A library that selects good defaults for Om Next, but simplifies a number of things, and has a lot of documentation.
Definitely looking at fulcro thanks for the tip.
Hi all, is there any documentation on how the parser should be able to respond to component instance queries changing?
for example:
- You have a component class SomeComponent
, which defines some base query.
- When clicking on an instance of SomeComponent
, you want to be able to get more data. so you use either set-query!
or update-query!
.
Presumably, it’s the read
‘s job to make sure every instance gets the appropriate data, and I’ve seen om/db->tree
perform this job, albeit inconsistently. I’m not sure how it works at all. @_@ Would be great if someone could point me in the right direction.