Why do browsers allows JS from other domains to run
I've never understood i) why a site would trust other sites to host code for them and ii) why browsers allow one site to run scripts from another.
If I ship an app I don't expect the users to download loads of components from third parties, i get the third party components, bundle and test them then distribute. This is the same thing.
I'm aware the genie is out of the bottle on this one but it grinds my gears. I get asked how to run scripts from other sites at job interviews, my answer is always "I would never do that, it's unprofessional". Doesn't get me many jobs mind.....