[BUGFIX beta] Cleanup view teardown.#13775
Merged
krisselden merged 2 commits intomasterfrom Jul 1, 2016
Merged
Conversation
| } | ||
|
|
||
| view.destroy(); | ||
| if (!view.isDestroying) { |
Member
There was a problem hiding this comment.
should we guard against both isDestroying and isDestroyed
Contributor
Author
There was a problem hiding this comment.
we don't unset isDestroying when we set isDestroyed but I can add that
Member
There was a problem hiding this comment.
ah, then its not needed. Seems good
44e7ecd to
08aaac7
Compare
Member
|
OK, I added regression tests for the various scenarios that were tweaked here (including the specific issues linked in the description). |
Contributor
Author
|
@rwjblue thank you so much for doing these tests. |
* [Glimmer] Ensure `.parentView` is present at creation. * Add tests for `.parentView` and `.element` in each lifecycle hook. * Remove duplicated `parentView` manipulation (this is now done as part of `renderer.remove`). * Add test ensuring `willDestroyElement` is called for inverse. * Ensure element in DOM during willDestroyElement.
4026ff2 to
9228bb8
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
.parentViewis available in all hooks..elementis available in appropriate hooks.willDestroyElementis called for components invoked from the{{else}}hook of an{{#eachwillDestroyElement not firing in {{each}} else #12716.this.parentViewis available inwillDestroyElementparentView undefined during willDestroyElement #12080.willDestroyElementis called before actual destruction for components rendered with{{componenthelper.This should fix #12080 #12716 and #13028