It appears that the positioning of filter: none;
in CSS has a significant impact on speed in Safari. Can someone offer a detailed explanation of what is going on?
Compare the following two examples in Safari only
Example 1: (Having filter: none;
at the end of the CSS rule slows down Safari)
Example 1 (Slow on safari)
section#pitches>div>div:hover {
opacity: 0.6;
filter: grayscale(0%);
-webkit-filter: grayscale(0%);
filter: none; /* IE 6-9 */
}
Example 2: (Moving filter: none;
above other browser-specific filters improves performance significantly)
Example 2 (Much faster)
section#pitches>div>div:hover {
opacity: 0.6;
filter: grayscale(0%);
filter: none; /* IE 6-9 */
-webkit-filter: grayscale(0%);
}
I've tried researching online for an explanation but haven't had any luck.
I have my own theories, but from what I understand, CSS does not necessarily stop checking other rules upon encountering something like filter: none;
.