Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failing test for {{component}} keyword teardown. #11329

Merged
merged 3 commits into from
Jun 12, 2015
Merged

Conversation

rwjblue
Copy link
Member

@rwjblue rwjblue commented Jun 3, 2015

Currently, the {{component}} keyword does not teardown previously created components
when swapping. This test demonstrates that.

JSBin Demo: http://emberjs.jsbin.com/rwjblue/571/edit.

Currently, the `{{component}}` keyword does not teardown previously created components
when swapping.  This test demonstrates that.
@rwjblue rwjblue added this to the 1.13.0 milestone Jun 3, 2015
Most of the infrastructure around components assumes they are static
(e.g. <my-component> cannot become a <foo-component> after it is
rendered). As such, there were some holes in destruction for the one
dynamic case (the {{component}} helper).

This commit detects when the underlying component has changed and
ensures that the component is scheduled for destruction before the new
component is swapped in.

It also fixes a similar issue with the view helper.
rwjblue added a commit that referenced this pull request Jun 12, 2015
Failing test for {{component}} keyword teardown.
@rwjblue rwjblue merged commit eb68b3e into master Jun 12, 2015
@rwjblue rwjblue deleted the teardown-component branch June 12, 2015 02:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants