Never Forget To Set An Image Alt Attribute Again

Today I learned how never to forget setting an alt tag attribute on an image tag again:

  img:not([alt]) {
    outline: 4px dashed lime;

Add this CSS snippet to your global CSS file. The next time you forget to set that alt tag, you will see the pretty dashed line around your image.

Posted on CuteMachine in css.

Jo's Profile ImageWritten by Jo who lives and works in Frankfurt building digital doodah. Stalk him on Twitter.

TOS • Privacy • Disclaimer