The problem is there's no liability for doing so. If the arbitrary JavaScript would make the ad company liable for tens of thousands in damages per user there would be a lot of innovation around making ad delivery safe.
Sure seems like in any other context, there would be liability.
We just never moved past the 1980s mindset of computers being mysterious black boxes.
Imagine if pharmaceutical companies knowingly purchased ingredients from suppliers that were known to randomly include toxic materials in their product.
Would we hold everyone in the chain completely blameless?
The advertising company should be ultimately responsible, however the ad network and especially the site showing the ads needs to face repercussions as well. Until we start prosecuting publishers for hosting malware the ad blocker will stay up.