does not remove <transition> element if onLeave handler provided #5
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
So the real correct way to do this seems to be to fix this function
getHookArgumentsLength, however it seems that it has a hard time analyzing the number of arguments in the vue-to-react transpilation scheme setup here.I could be wrong, so consider this just an indicator of what needs to be fixed.
Essentially, my fix is a weaker assumption:
onLeavehandler, it means do not remove the element.However, in a real Vue app, you likely can use such handlers for other things without manually removing the element, which is why
getHookArgumentsLengthexists to smooth things over. My guess is those situations are just edge cases. 90% of the time if you are going to provide such a handler you will finish the job and calldoneyourself.Hopefully this can get merged sooner than later, as I'd like to present your repo (since you're the original creator) rather than a fork.