Collect quirks mode #40
Comments
This would be easy to do using a WPT custom metric e.g. [compat-mode] Here's a test I just did with it in - http://www.webpagetest.org/custom_metrics.php?test=141209_VX_91e6174f5596adc66ef6aaa019aa9eb4&run=1&cached=0 |
Why would this be useful? What does it reveal? |
It is useful to research how many pages rely on a specific quirk to inform whether the quirk can be dropped from browsers, or to study pages that use a specific quirk to inform which browser's implementation is most compatible, or compatible enough, for the others to adopt. I maintain a |
I'm not sure how mainstream this is - how much it would actually be used. Can you give me a specific example? |
I can say that I've wanted this many times. Most recently checking if the -webkit-text CSS value could be removed from chromium, which only affects pages in quirks mode. That particular example gave few enough hits that it wasn't so time consuming to just manually inspect the doctype of each result, but that's not always the case. Browsers still have many quirks that may not be necessary for web compat, so would be nice to remove, but the lack of collecting document.compatMode makes it take more time to analyse. |
I can imagine that this isn't mainstream at all; possibly it's just me who wants this. I can whip up a PR for this if I get some guidance. |
Sounds like it could easily be implemented as a custom metric (JS that runs at the end of a test). The custom metrics for HA are here. |
Thx, PR at #58 |
(Documenting a workaround here...) Query to collect pages that most likely are quirks mode (the regexp isn't as exact as the spec).
|
Fix #40: Add custom metric for document.compatMode
It would be useful to store which rendering mode was used for the top-level document. There is a
doctype
field but it is not obvious how to map that to quirkyness and it will not be quite correct.document.compatMode === 'BackCompat' // quirks mode
document.compatMode === 'CSS1Compat' // standards mode or almost standards mode
The text was updated successfully, but these errors were encountered: