-
Notifications
You must be signed in to change notification settings - Fork 20.5k
#4087 - insertAfter, insertBefore, etc do not work when destination is original element #1047
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
Conversation
…ug_4087_2.\nAdded unit test as well
Too bad the element needs to be carried around so much. I'm also worried about the |
Pulling in @gibson042 since he's been involved in this too. |
I considered that, but in order to flag the element of interest we'd have to iterate through each of the selected elements and compare against each of the elements to be inserted into that fragment - which I believe has equal complexity to this solution... unless you have a better way in mind? |
Nothing in particular ... 😿 Let me think a bit about it. |
src/manipulation.js
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd like this better if were handled in the body instead of the condition: value = jQuery( value ).not( this ).detach()
That way we still detach elements in value
that aren't in this
, and avoid calling jQuery( value )
twice.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
@jquerybot retest |
…logic of a unit, server-side and client-side, is contained within the unit itself. Nearly all ajax unit tests take advantage of the new 'framework'. Lots of files got deleted because they became redundant or weren't used anymore.
…ug_4087_2.\nAdded unit test as well
…xed expectation of unit test in complex case with replaceAll
I rebased my changes for #4087 here with master. |
@PaulBRamos can you put together a new pull request now that we've made a mess of this one and whacked the frag cache in the process? It will be easier to see what is left. Sorry! |
Sure thing, no problem. |
No description provided.