Instantly share code, notes, and snippets.
Iteration pattern from:
Alternative click approaches:
I've also used the same approach in an interval to banish adverts that are on the page and continue to appear in 'infinite scroll pages'
var advert = document.querySelector(".dismiss-advert");