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

Any thoughts on reordering the options so that remove/update is performed last? #19

Open
ProLoser opened this issue Feb 18, 2014 · 2 comments

Comments

@ProLoser
Copy link
Contributor

This way people can use DOM that will eventually be removed as a selector BEFORE it's gone.

@cgross
Copy link
Owner

cgross commented Feb 19, 2014

After I merged your PR, I did change the order a bit. Reads are always first, then removes, then all other modification actions. I did it this way so a typical concat/minify step could be done with one dom_munger task. So you do the read to get the scripts, then you remove those script tags, then you add the final one with the concat-ed minified script.

I was also considering some way to declare a desired order (for example, an order number that could be placed on each action but that seems a little in-elegant).

The latest 3.4 release is where I made the changes. If you have that and still need a different order than [read, remove, everything else], please let me know your use case. With the array feature you added, its really nice to get all dom_munger operations down into one task.

@ProLoser
Copy link
Contributor Author

I REALLY feel that remove should be absolutely last. This way, I can read it, and then do an after/before on it, and then finally remove it.

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

No branches or pull requests

2 participants