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

Make sure shuffling doesn't cause index changes to propagate to levels referencing a deeper index #1460

Merged
merged 2 commits into from
Nov 11, 2014

Conversation

evs-chris
Copy link
Contributor

Shuffling propagates new indices through child fragments, which was causing nested iterations to have their indices wiped out. In order to track which sections are iterative, this adds a currentSubtype to the section which gets set upon re-evaluation. The currentSubtype currently only distinguishes between IF, EACH, and WITH. If rebind is called on a section that is and EACH, the index is removed (set to undefined) when rebinding its children so that the children don't get the index from upstream. The Fragment.rebind is also updated to ignore undefined index changes.

This fixes #1457

evs-chris added a commit that referenced this pull request Nov 11, 2014
Make sure shuffling doesn't cause index changes to propagate to levels referencing a deeper index
@evs-chris evs-chris merged commit 5a87c6f into ractivejs:dev Nov 11, 2014
@evs-chris evs-chris mentioned this pull request Nov 13, 2014
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.

removing an object from an array "unrenders" some sub-objects from the objects not removed
1 participant