Back to feed
Dev.to
Dev.to
7/17/2026
Keeping code alive on a DOM you don't own: 12-year Chrome extension story

Keeping code alive on a DOM you don't own: 12-year Chrome extension story

Short summary

A developer shares 12 years of maintaining a Chrome extension that sorts Hacker News posts, relying on HN's unchanging HTML structure. When HN added a logo row in March 2026, positional CSS selectors broke silently on every user's machine. The fix involved switching to semantic anchors using stable class names and adding a GitHub Action to monitor HN's HTML daily.

  • Chrome extension depended on HN's exact HTML table structure for 12 years
  • Positional CSS selectors broke silently when HN added a logo row in March 2026
  • Solution: semantic anchors using stable class names plus automated HTML monitoring

Generated with AI, which can make mistakes.

Is this a good recommendation for you?

Comments

Failed to load comments. Please try again.

Explore more