2 ms·
Doing "the best" by inventing some way to continue in the face of an error has caused nothing but grievous harm to the world wide web. The developer of the HTM
by kazinator 9y ago
Doing "the best" by inventing some way to continue in the face of an error has caused nothing but grievous harm to the world wide web.
The developer of the HTML markup must not rely on the browser doing "its best" with bad HTML.
During development, it's helpful if the implementation finds as many errors as possible in one pass and flags them all. Whether or not anything is rendered is immaterial; the HTML writer should fix everything.
The end user shouldn't see any errors, because they all blew up in the HTML writer's face and were fixed.
It is a fact that rendering happens in parallel with downloading a web page. So yes, renderers should be able to render a prefix of a web page, up to the first error, because the situation is entirely possible that only that prefix has been downloaded and the error is not yet seen. Renderers should not delay rendering until the entire page is seen; something has to be rendered when the prefix is available, but the erroneous text which immediately follows has not yet been seen.
Beyond that, no. Stop at the first error and splash a big red diagnostic into the output, so the user can see that the HTML producer screwed up.