0

Create simple web page like this one:

<h1>Heading</h1>
<p>Simple text. <strong>Bold</strong> text.</p>

and open it in any mainstream web browser. The rendering will be the same: the heading will be large and bold, the text in strong tag will be just bold.

Are these default CSS-rules (h1 { font-size: large; font-weight: bold; } strong { font-weight: bold; }) a part of HTML standard?

(Yes, I know, technically these CSS-rules comes from stylesheet which is built in the browser, but this information doesn't directly answer my question).

john c. j.
  • 725
  • 5
  • 28
  • 81
  • which HTML standards? It varies depending on your Doctype – Liam Jul 25 '18 at 10:56
  • @Liam Any of them. No, it's not duplicatge. The linked question is about technical side. My question is about standart. – john c. j. Jul 25 '18 at 10:57
  • You can't say any of them, there are lots and they can vary a lot. Seems this isn't standardised anyway – Liam Jul 25 '18 at 10:57
  • What the $##? It's not a duplicate. @Quentin, I asked about standart, not about technical side. – john c. j. Jul 25 '18 at 10:59
  • It is a duplicate [the answer is No](https://stackoverflow.com/a/30980950/542251) – Liam Jul 25 '18 at 11:00
  • 2
    I’d call what https://www.w3.org/TR/html5/rendering.html#the-css-user-agent-style-sheet-and-presentational-hints describes “standard” in this regard. – CBroe Jul 25 '18 at 11:04
  • @CBroe Thanks! Not sure I understand correctly, but it seems, indeed, a part of standard? (Well, it is just *recommendation*, but still, this recommendation is a part of standard's official text). – john c. j. Jul 25 '18 at 11:17
  • 1
    These are the recommendations that browsers are supposed to implement as a “common basis”. With the HTML 4.01 spec, there was an explicit “sample stylesheet” provided, https://www.w3.org/TR/CSS2/sample.html You’ll notice that in both cases it says these are recommendations/suggestions, so you would not be able to “nail” any browser vendor for not being “standards compliant” if they did not strictly follow those. – CBroe Jul 25 '18 at 11:23
  • 1
    So whether you’d want to call that an actual “standard” in those regards, might be debatable. The HTML 4.01 spec says this was “based on extensive research into current UA practice”, so rather a compendium of what already was “common practice” at the time. The HTML5 version explains “must” vs. “expected” in that regard in the introduction section on top. – CBroe Jul 25 '18 at 11:23
  • @CBroe Thanks again! Your comments are, actually, an answer, which I believe could be multiple time upvoted. It is a shame that the question was closed with a link to completely unrelated answer. (I mean, Liam's link to Quentin's answer). I hope it will be reopened! – john c. j. Jul 25 '18 at 11:38

0 Answers0