3 ms·
I've had luck blocking scrapers by overwriting JavaScript methods " a.getElementsByTagName = function (...args) {//Clear page content}" One can also hide c
by gulugawa 9mo ago
I've had luck blocking scrapers by overwriting JavaScript methods
" a.getElementsByTagName = function (...args) {//Clear page content}"
One can also hide components inside Shadow DOM to make it harder to scrape.
However, these methods will interfere with automated testing tools such as Playwright and Selenium. Also, search engine indexing is likely to be affected.
- bogwog 9mo agoThis is a fun idea, especially if you make those functions procedurally generate garbage to get them stuck
- TurdF3rguson 9mo agoYou think you've had luck. The truth is you have no idea of knowing if this ever had any effect at all.