Communicate that quirks mode is bad and help transition to no-quirks mode
Reported by
sim...@opera.com,
Jun 23 2016
|
|||||
Issue descriptionI think devtools should communicate to the developer that a page is in quirks mode (except for about:blank pages that are not interacted with), and maybe also provide tools to help transition from quirks mode to no-quirks mode. Sometimes when people have a problem with CSS and they find removing the doctype "fixes" it, they assume that using quirks mode is the right way of doing things. I think we should communicate better that it's not. Quirks mode has behaviors that are confusing and generally it is recommended to not use it. For example IDs and class names being case-insensitive can introduce bugs. Ideas to communicate quirks mode being active: * The DOM view can have an error message for the doctype (or at the top if there is no doctype). * There could be a warning logged in the console. * Firefox error-highlights parse errors in "view source", which highlights quirky doctypes or if the first thing is a tag instead of a doctype. Ideas to help transition from quirks mode to no-quirks mode: * Highlight what causes layout to be different in quirks mode. I don't have good ideas about how but I think this is what people will have the most trouble with. (Maybe highlight quirk.css UA styles in Styles tab?) * Error-highlight CSS values in the Styles tab that are using https://quirks.spec.whatwg.org/#the-hashless-hex-color-quirk or https://quirks.spec.whatwg.org/#the-unitless-length-quirk * Error-highlight ":active" and ":hover" selectors in Styles tab https://quirks.spec.whatwg.org/#the-active-and-hover-quirk * Highlight <p><table> HTML parser quirk somewhere (DOM view? console?). * etc; search for quirks in the codebase.
,
Jun 23 2016
,
Jun 23 2016
Note that the blocks ignore line-height quirk is also present in limited-quirks mode. But document.compatMode doesn't differentiate between limited-quirks and no-quirks.
,
Jun 30 2016
> * The DOM view can have an error message for the doctype (or at the top if there is no doctype). Something like this is what I had in mind. To implement, add the message (whether or not there is a doctype) if document.compatMode === 'BackCompat'.
,
Jun 30 2016
Paul, can you help triage this request into y'all's backlog?
,
Nov 18 2016
,
Nov 18 2016
The mockup seems pretty non-intrusive, less scary than a console message at least. Ping Paul :)
,
Aug 1
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by sim...@opera.com
, Jun 23 2016