3 ms·
Because if the spec didn't, every engine would do things their own way and no website would work in more than one browser.
by kyrias 14y ago
Because if the spec didn't, every engine would do things their own way and no website would work in more than one browser.
- IgorPartola 14y agoWe do need a spec, I'm not arguing against it. I am just tired of the fact that I can position elements via many conflicting methods: - position: absolute/relative/fixed + top/left values - float: left/right - positive/negative margins - float values of other elements Yet cannot do simple things like tell a block element to take up all available height. The spec focuses on various types of data that could be represented. For example we have a <code> tag. This is done in an attempt to be semantic. However, it fails at being comprehensive, and ends up falling back on things like <code class="python"> instead of <python>. The distinction between <code>, <var>, <span>, <label>, and other inline elements is completely arbitrary and which elements get to be first class citizens is also arbitrary. Giving up and saying that there are only <inline> and <block> elements would simplify things a whole lot. If you can then "subclass" a <block> to create a <p> element or subclass an <inline> element to make a <lable>, go for it!