Fork me on GitHub

Is there any way to make a select component whose query does not compose back to root? I don't want to have to pass props through for every select, I thought I might be able to do this with an Ident.


The parser is being called but om doesn't seem to be passing props to the component. I made my own lookup table on state :select/by-id. I'm also adding the ident as a tailing argument to transact!


It would be a good fit for component local state but I would quite like to store things in app-state if possible.


is the component being re-rendered?


I've changed it to use component local state for now but I'd like for it to be built into app-state so I can jump across all the states.


I thought maybe the component isn't being indexed because I'm not including the query in a parent and composing to root..


if it's not re-rendering but the data is updating in the reconciler you could try a "read transact" (om/transact [:select/by-id ~id]) i've used that pattern for remotes data updates to trigger updates, haven't tried from the parser though


ah, rereading what you said, i think you'll need the select component's query in your root, you may not have to pass the data down as long as its query is present in the root


I see, in that case I'd need a huge list of idents in my root component for all the select menus in my application


looks like you can have free reign into how a component gets its data


Oh, another hidden gem for me to abuse 🙂


haha yea, i haven't played with that yet, but i probably will get there - i'd really like to avoid having to wire all the state down the ui tree


I recently uploaded a video directed at helping people understand how we handle state, remotes, and the removal of a need for a client-side Om Next parser in Untangled. Thought it might be interesting to those of you that are thinking through the Om Next patterns. Might shed some light.


this is great, thank you!