5 ms·
Somewhat interesting, perhaps, is the fact that this page itself has the following markup: <main id="content" class="group" role="main"> <div class
by codeka 13y ago
Somewhat interesting, perhaps, is the fact that this page itself has the following markup:
<main id="content" class="group" role="main">
<div class="main">
...
I, too, have tried to use semantic markup. Unfortunately, except for the most straight-forward of layouts, it's very hard to do. Though I guess there was also a time when non-table-based layouts was considered harder than it was worth...
- Swizec 13y agoArguably most modern websites might as well be using tables considering how they use divs.
- grandalf 13y agoyes. this is an under-appreciated fact.
- mmatants 13y agoSemantic = for developers. I.e. not in the "make it nice for web crawlers" sense, but for readability of template code. So for my own workflow, I have been quite comfortable being a "semantic stickler", where markup is written first and with only a general wireframe. CSS classes are added sparingly, to mark separate areas of concern for LESS/SCSS grouping. And then styling work begins, during which I try to avoid adding presentational fluff to markup at all costs. It's hard, but CSS3 allows a surprising amount of power. The rule of thumb is: clean template code is worth dirty CSS hacks. CSS is going to be shit anyway, due to its inherent qualities as a language. So might as well make templates awesome. And again, this is for developers' sanity more than anything to do with "semantic web" or whatever.