Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

another trick is adding speculation rules on MPA sites. so when you hover over a link the page gets prerendered. For example, my initial page takes ~80ms, but navigating to other pages take 20ms

    prerender: [
      {
         where: { href_matches: '/*' },
         eagerness: 'moderate'
      }
    ]

That doesn't work on Safari, FF, and Brave, but you could do something like this:

https://github.com/ericfortis/mockaton/blob/main/www/src/_as...





Most adblockers/privacy extensions disable this.

uBlock Origin does it by default for instance.


Do they block <link rel=prefetch> completely?

On Brave, the workaround on that linked snippet bypasses their blocking.


Well, uBlock Origin sets network.prefetch-next=false and network.dns.disablePrefetch=true, so yes.

The reason is that browser prefetching may hit URLs that were intended to be blocked.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: