Open kuraga opened 9 years ago
Generally speaking I think virtual-hyperscript is both too big and too slow. I'm down for removing things like ev-click and other magical specifics if there is some clean way for mercury to customize virtual-hyperscript to actually provide this functionality.
@Raynos should be more concerned about back compat
Multiple people have asked fore ways to customize virtual-hyperscript; we should look into those issues and look there; then fix mercury.
While this is in discussion, I wanted to throw in in the possibility of being able to customise virtual-hyperscript to have React-style control over when DOM elements are destroyed, as documented here. Particularly,
componentWillLeave(callback)
This is called when the child has been removed from the
ReactTransitionGroup
. Though the child has been removed,ReactTransitionGroup
will keep it in the DOM untilcallback
is called.
This appears to be useful for animations.
(as a continuation of #219)
Good day, @Matt-Esch !
Don't you think that's possible to remove suport of
ev-*
attributes at all, do you? Because:Even if we remove it, it's simple to use:
h('button', { 'ev-click': new EvHook(value) })
instead ofh('button', { 'ev-click': value })
.But
virtual-dom
won't use so specific component. What do you think? Thanks.