‹ BackHN Continuity

Thread

Ten lines of code that changed my world

148 points · 46 comments · dimonomid

  1. throw34889 · · focus · HN ↗
    For debugging CSS, I prefer something along the lines of:

        * {
          outline: 1px solid hotpink !important;
          outline-offset: -1px !important;
        }
    
    As in most cases the above snippet doesn't reflow content.

    Exercise to the reader is to turn the above into a javascript bookmarklet toggle, and to add support for shading margins and padding.

    1. chias · · focus · HN ↗
      if you're using firefox, you can generally juts ctrl-click on the page. It'll draw outlines around every child element without reflowing.
Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.