Skip to content
This repository has been archived by the owner on Oct 1, 2023. It is now read-only.

Remove scripts from DOM #3

Open
zlalanne opened this issue Aug 25, 2014 · 4 comments
Open

Remove scripts from DOM #3

zlalanne opened this issue Aug 25, 2014 · 4 comments

Comments

@zlalanne
Copy link
Contributor

Would be nice to be able to remove scripts from the DOM once the page/url changes. This way the DOM doesn't end up with a ton of script tags. Don't think this is a huge performance concern, just a nice feature.

@urish
Copy link
Owner

urish commented Aug 30, 2014

Would be nice indeed. Is there any proposed way to achieve this automatically?

@zlalanne
Copy link
Contributor Author

zlalanne commented Sep 2, 2014

Maybe keep track of the elements in an array as their loaded and on a route change remove from DOM. Haven't tried it yet though.

@vaneshmali
Copy link

@zlalanne : Same, I want. Using Requirejs with AngularAMD. Want to remove script from DOM. If is there any solution for this then it will be better for me!

@soumak77
Copy link

I've been using this solution and it seems to work perfectly: http://stackoverflow.com/a/9425964

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants