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

Don't detach pre-existing HTML when view's el is already in the region #3260

Merged

Commits on Nov 15, 2016

  1. Don't detach pre-existing HTML when view's el is already in the region

    Resolves marionettejs#3227
    
    This PR also moves some of `Region.show` into a `_setupChildView` function which mirrors what is happening in a CollectionView currently and helps reduce the length of the `show` function which grew to handle the should empty check.
    
    In the specs, there was a failing test regarding “when setting the "replaceElement" class option”.  I believe this test was failing because it was reusing `this.view` which wasn’t cleaned up in a prior test.  So effectively `this.view` was currently already shown in another region.  I switched this to `this.view1` which is instantiated as part of this `describe` block (or closer at least) and should be better for these tests.
    paulfalgout committed Nov 15, 2016
    Configuration menu
    Copy the full SHA
    0f01915 View commit details
    Browse the repository at this point in the history