Lint HTML with CSS

1 min. read Published: Updated at:

Ire Aderinokun just posted an article on his blog bitsofco.de about linting of HTML with CSS. The idea: visually mark HTML elements with the help of CSS if the elements are broken or incomplete.

A small example: mark all faulty or missing link targets

<code class="language-css">a:not([href])  
a:[href="#"],  
a:[href=""],  
a[href*="javascript:void(0)"] {
  border: 2px solid red;
}
</code>

Webmentions

0 Mentions
0 Reposts
Likes