Refactorings to the custom renderer API in preparation of deferred mount/unmounting of elements. Lots of inlining of functions whose structure didn’t really make much sense. Like why did we call a generic commit() from updateChildren(), when within the commit() function we would again start doing different logic based on committing element tag.
Beeg changes:
[x] Overhaul of the internal renderer API (yet again).
[x] Stop passing elements into Renderer methods.
[x] Disappear the janky Element.hadChildren computed property.
[x] Get rid of element flags.
[x] Pass old props/children to the patch and arrange methods, in preparation for solving #204 and going back to a nicer story for removed properties.
[x] Rename complete() to flush(), and fix some bugs created in (#206) method for (#180).
[x] Move the internal renderer methods onto a RendererImpl interface, which is passed to the constructor.
[x] Consider reordering node and tag parameters in patch(),arrange() etc.
[x] Make patch() work per individual prop?
[x] Clean up the internal functions to support future changes.
[x] Kill updateChildren().
[x] Replace updateChildren() with a diffChildren() function which doesn’t do the committing part.
[x] Kill commit().
[x] Move commitCtx() out of commit.
[x] Kill update()
[x] Don’t call update() from Renderer.render().
[x] Move Fragment updating logic out of update().
[x] Cache parses for Raw elements.
[x] Create a “retainer” class to store all the internal state which we’re currently storing on elements.
[x] Consider using the newly retained childValues cached property in more places.
[x] Store the old childValues on component contexts.
[x] Avoid rearranging when components produce the same nodes.
[x] Use cached childValues in getChildValues/getValue functions.
[x] DOM renderer upgrades
[x] #204
[x] Use the Copy tag for new uncontrolled behavior???????
[x] #175
[x] #209
[x] crank-static (TODO in a separate PR)
[x] Async mounting and unmounting (TODO in a separate PR)
Refactorings to the custom renderer API in preparation of deferred mount/unmounting of elements. Lots of inlining of functions whose structure didn’t really make much sense. Like why did we call a generic
commit()
fromupdateChildren()
, when within thecommit()
function we would again start doing different logic based on committing element tag.Beeg changes:
Element.hadChildren
computed property.complete()
toflush()
, and fix some bugs created in (#206) method for (#180).RendererImpl
interface, which is passed to the constructor.node
andtag
parameters inpatch()
,arrange()
etc.patch()
work per individual prop?updateChildren()
.updateChildren()
with adiffChildren()
function which doesn’t do the committing part.commit()
.commitCtx()
out of commit.update()
update()
fromRenderer.render()
.update()
.Copy
tag for new uncontrolled behavior???????#209(TODO in a separate PR)crank-static
Async mounting and unmounting(TODO in a separate PR)