treehousedev / treehouse

https://treehouse.sh
MIT License
154 stars 12 forks source link

Issue 313 #315

Closed lritter79 closed 4 days ago

lritter79 commented 5 days ago
lritter79 commented 5 days ago

Might be a heavy lift, but perhaps you need to modify the childrenview function to take in params as well to pass state? Just my guess since keeping the output in the parent state is what got it working before.

progrium commented 4 days ago

Might be a heavy lift, but perhaps you need to modify the childrenview function to take in params as well to pass state? Just my guess since keeping the output in the parent state is what got it working before.

no because the component type it returns is then used, passing the node as a attr/prop, which lets you access the treehouse component. but we don't need the output state there. it should be able to keep it in its own mithril component state (via vnode)

lritter79 commented 4 days ago

Made some fixes based on feedback, switching to a fxnal component with jsx the fix. Closing this PR to start another one.