<link href="http://my.c.css" rel="stylesheet" type="text/css/bogus"><link href="http://my.nc.css" rel="stylesheet" type="text/css/bogus">You used type="text/css"?
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/5b0cd821-c49f-4756-a742-75069c1b5e30%40googlegroups.com.
Thanks. I tried that first but it didn't work. Funny, since it's the code Google says we should use.
You received this message because you are subscribed to a topic in the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pagespeed-insights-discuss/6zQW2qbN5VI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BECvjZpyCj-jRgW8g1Wk%3DG_C1CT4UoMWd_6zq3Gsfar29g%40mail.gmail.com.
Try this code to defer loading: https://github.com/filamentgroup/loadCSS
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-discuss+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/6e5d1174-be33-4ea5-8366-9ef24e020b62%40googlegroups.com.
<html>
<head>
<style>
.blue{color:blue;}
</style>
</head>
<body>
<div class="blue">
Hello, world!
</div>
<noscript id="deferred-styles">
<link rel="stylesheet" type="text/css" href="small.css"/>
</noscript>
<script>
var loadDeferredStyles = function() {
var addStylesNode = document.getElementById("deferred-styles");
var replacement = document.createElement("div");
replacement.innerHTML = addStylesNode.textContent;
document.body.appendChild(replacement)
addStylesNode.parentElement.removeChild(addStylesNode);
};
var raf = requestAnimationFrame || mozRequestAnimationFrame ||
webkitRequestAnimationFrame || msRequestAnimationFrame;
if (raf) raf(function() { window.setTimeout(loadDeferredStyles, 0); });
else window.addEventListener('load', loadDeferredStyles);
</script>
</body>
</html>
Thanks Joshua,I managed to figure it out. I’m using a combination of inline CSS (critical) and delay-loaded (non-critical).Pagespeed works only when I delay loading for about 6 or 7 seconds. I’m loading the CSS after DOMContentLoaded but Pagespeed seems unable to detect this (seems like a minor bug) so I have to use setTimeout.To fix finally, I isolated Pagespeed Insights traffic to load the CSS after 6 to 7 seconds, and then I delay-loaded the CSS the original way I was doing it without setTimeout.Works like a charm.
From: 'Joshua Marantz' via pagespeed-insights-discuss
Reply-To: <pagespeed-insights-discuss@googlegroups.com>
Date: Monday, August 8, 2016 at 7:29 PM
To: pagespeed-insights-discuss
Subject: Re: [pagespeed-insights-discuss] Re: Pagespeed Insights reporting Should-Fix for content not loaded
Without seeing the details (waterfall) of your run, I suspect that the problem isn't how you are loading the CSS, but rather that the CSS you are delay-loading is required to render your page. Delay-loading critical CSS won't help your users or your PageSpeed score; it will only hurt.You need to inline the critical CSS (which is hopefully quite small) and delay-load the non-critical CSS.Sound complicated? Try mod_pagespeed which should do it all for you (disclaimer -- that's what my team works on :).-Josh
On Mon, Aug 8, 2016 at 11:34 AM, Rick Steinwand <colc...@702com.net> wrote:
Try this code to defer loading: https://github.com/filamentgroup/loadCSS
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-discuss+unsubsc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/6e5d1174-be33-4ea5-8366-9ef24e020b62%40googlegroups.com.
--
You received this message because you are subscribed to a topic in the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pagespeed-insights-discuss/6zQW2qbN5VI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-discuss+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BED4cNR_A%2BW%2BBAHaJFP21nN1TJHfDhBeGLMkQiXMQtn%2BEA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-discuss+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/34F072A7-D6E1-48C4-BFB9-0A500B022915%40restive.io.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-discuss+unsubsc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BED4cNR_A%2BW%2BBAHaJFP21nN1TJHfDhBeGLMkQiXMQtn%2BEA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-discuss+unsubsc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/34F072A7-D6E1-48C4-BFB9-0A500B022915%40restive.io.
--
You received this message because you are subscribed to a topic in the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pagespeed-insights-discuss/6zQW2qbN5VI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-discuss+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BEBpvtnmBuTAZ_CX%3DvhpgJWXgMf9x%3DCN3sD%2BKVeDzjKHaQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-discuss+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/C6DF992E-7F6D-49B1-AB24-B1B3C5A95E4A%40restive.io.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-discuss+unsubsc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BEBpvtnmBuTAZ_CX%3DvhpgJWXgMf9x%3DCN3sD%2BKVeDzjKHaQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-discuss+unsubsc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/C6DF992E-7F6D-49B1-AB24-B1B3C5A95E4A%40restive.io.
--
You received this message because you are subscribed to a topic in the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pagespeed-insights-discuss/6zQW2qbN5VI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-discuss+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BEDCMtO_5gbfntgDnxe2UqBbkk%3D8sF0phGtY8aY901iW3Q%40mail.gmail.com.
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-discuss+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/5D4D59F1-ED5D-42BD-8E49-F6A72AA0406D%40restive.io.
Thanks for the advice Josh, but that still doesn't answer the question of blocking vs non-blocking.
Pagespeed Insights says it's blocking when it is not, and that is a bug, is it not?! It really doesn't matter what technique or timing signal I use as long as it delivers the intended result.
I recorded a first-view Speed Index of 566 over Cable Internet + DomInteractive at less than 350 ms so I'd say our technique works really well. We also worked hard to make sure it passed muster regarding non-blocking.
So, if DomInteractive is 350ms, and I wait for 4 more seconds before exposing the CSS, and you still say I'm blocking, that can't be my fault now, can it?!
I should also point out that the code we're using for the shielded Pagespeed traffic uses virtually the same requestAnimationFrame code you recommend, only delayed. Unfortunately, we just couldn't get it to work right after days of tweaking, which included lazy-loading CSS before the closing body tag + exposing after 3 seconds.
What we're doing is part of a bigger JavaScript toolkit, and one of the things we're very particular about is performance. I'm not against your technique at all. We tried it several times but no dice.
Thanks for the time.
Obi.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/6e5d1174-be33-4ea5-8366-9ef24e020b62%40googlegroups.com.
--
You received this message because you are subscribed to a topic in the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pagespeed-insights-discuss/6zQW2qbN5VI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BED4cNR_A%2BW%2BBAHaJFP21nN1TJHfDhBeGLMkQiXMQtn%2BEA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/34F072A7-D6E1-48C4-BFB9-0A500B022915%40restive.io.
--
You received this message because you are subscribed to a topic in the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pagespeed-insights-discuss/6zQW2qbN5VI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BEBpvtnmBuTAZ_CX%3DvhpgJWXgMf9x%3DCN3sD%2BKVeDzjKHaQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/C6DF992E-7F6D-49B1-AB24-B1B3C5A95E4A%40restive.io.
--
You received this message because you are subscribed to a topic in the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pagespeed-insights-discuss/6zQW2qbN5VI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BEDCMtO_5gbfntgDnxe2UqBbkk%3D8sF0phGtY8aY901iW3Q%40mail.gmail.com.
--
You received this message because you are subscribed to the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/5D4D59F1-ED5D-42BD-8E49-F6A72AA0406D%40restive.io.
--
You received this message because you are subscribed to a topic in the Google Groups "pagespeed-insights-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pagespeed-insights-discuss/6zQW2qbN5VI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pagespeed-insights-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pagespeed-insights-discuss/CAGKR%2BEAOn1rTeQ9-Mx%3D%3Dh8aX4X3fbQy_rYE2PWRE5a%3D3HWBh1w%40mail.gmail.com.