Comment by VladVladikoff

7 hours ago

This website hijacked my back button during a simple page load. You should fix that, it’s not an acceptable way to behave.

My habit of nearly always opening links to other sites in a new tab helps me avoid that annoyance for the most part.

For example, if I browse HN, I open the linked article in a new tab instead of in the same one where the comments are. And I close the tab as soon as I’m done looking at it. Whether that be a couple of seconds because of annoying dark patterns, or a long time thanks to being actually readable and interesting. From that tab I might navigate to another page on the same site if the site seems good. If they then pull horse crap with the browser history in that tab I will most likely close the tab and not read anything more on that site. If I repeatedly get annoyed by a domain from having gone to it and found dark patterns I will eventually remember that the whole site is bad and stop clicking any links to it either. But mostly I don’t have to remember so many sites to actively avoid. Closing a tab is cheap when all of the history is from the same site that tab was opened for in the first place.

It’s unfortunate and annoying that they get to play tricks with dark patterns still, and I wish nobody did that / could do that in the first place. In general I mean. I dont know if this particular page does it intentionally or accidentally.

I usually try to not comment on it even if I do come across that. As I know many consider it off topic, and even the HN guidelines say to not comment on it [1]. But I still appreciate when others, like your comment here, point those things out and I then don’t click on to the linked article in the first place when I see comments about that unless other comments are indicating that the content itself is particularly interesting.

[1]: https://news.ycombinator.com/newsguidelines.html

> Please don't complain about tangential annoyances—e.g. article or website formats, name collisions, or back-button breakage. They're too common to be interesting.

  • I think this rule is quite unfortunate. Wouldn't we all be better off if sites that hijacked back buttons were just banned or at least had their posts hidden until they're fixed?

    Sure, they're somewhat common issues, but so are ads for malware served by Google. Surely we should call those out?

    • Honestly, I feel like browsers should handle this.

      Sites are always going to do malicious shit. The browser should know that when I hit the back button I want to go to the place I clicked that brought me here. SPAs have severely perverted this simple idea, but I’m sure browser devs can figure it out.

  • I generally open links in a new tab because browsers never seem to be able to consistently cache the previous page, so when I hit back it has to reload. A separate tab always avoids this. I even have a button on my mouse hardwired to Ctrl-W to quickly close these extra tabs.

I’m shocked that’s still possible, shouldn’t we be able to fix that at the browser level?

  • Just like how browsers disable or mute auto playing videos, they should be able to prevent back button hijacking until user has clicking a link or button.

    • Some websites like PC Gamer have some shitty middleware (that seems to be very careful to hide its identity, only appear once per session, and not immediately register on page load, probably to try to delay browsers banning the ever loving fuck out of their practices) that uses pushState to hijack the back button to try to SPAM more articles at you, probably in hopes of grabbing your attention. I would be in favor of permanently banning domains that do this even once (intentionally and not just getting hacked) from ever executing JavaScript ever again and forcing them to switch domains and lose their SEO.

    • Somehow some sites are able to get around the video autoplay, I especially notice it on news sites.

This only appeared to happen with Safari on my end. Edge and Firefox didn't appear to have the back button hijacked here. Maybe some browsers do block the behavior now? (or maybe ublock origin blocked it, I'm not sure)