om

Please ask the channel first, not @dnolen directly!
levitanong 2017-10-19T14:46:15.000803Z

Hey all, om innards question. When (and where in the source) do the props get stored in component local state? I’m running into what appears to be a competition between data in props and data in state, and the copy in state is winning out, causing a bunch of problems. Basis of my question: om props is running max-keys on basis-t to decide whether to return state or props. https://github.com/omcljs/om/blob/master/src/main/om/next.cljc#L1107

matthavener 2017-10-19T15:04:03.000508Z

props in react are passed in from the parent, so they aren’t really “stored” per-se

matthavener 2017-10-19T15:05:02.000421Z

if om.next does a targeted update to a component, its going to store the new values for the component in state, otherwise it would need to re-render from a parent

levitanong 2017-10-19T15:34:26.000117Z

@matthavener I see, that clears some things up. do you know which function does the storing of the new values for targeted updates to the component?

matthavener 2017-10-19T15:35:25.000377Z

I think its update-props!

matthavener 2017-10-19T15:35:44.000154Z

it all happens in reconcile!

levitanong 2017-10-19T15:57:18.000524Z

Awesome, thanks @matthavener!