4 ms·
Your tool looks very cool :) > The benefit of using tags (jsx) is that objects become fully managed I'm not sure I follow here. I assume that by 'become fully
by westoncb 8y ago
Your tool looks very cool :)
> The benefit of using tags (jsx) is that objects become fully managed
I'm not sure I follow here. I assume that by 'become fully managed' you mean that React will reconstruct as necessary based on what is declared in the jsx?
So maybe that is just the nature of writing React renderers specifically, the only option for getting your objects managed is to map them to jsx?
> The most clear indication to me is still effects.
This does look much nicer than other examples I've seen of using effects. I have only limited experience with them personally. They weren't needed for our tool. Incidentally I am probably setting up some SSAO on another project today though so I'll be likely be digging more into them later.
- mlsarecmg 8y agowith managed i mean that the view is now merely a reflection of state. Basically just like with the dom: {condition && <div>hello</div>} The div is there as long as the condition is true. But of course it can now also be a mesh, or a component that can clean itself up after the unmount. We did this manually before, which usually meant watching out for objects to remove themselves, they'll have to communicate up their hierarchy to inform parents and so on. This wasn't straight forward in three, so there was a lot of prototype hacking and terrible things like that, i'm so glad this will be all gone.