|
|
|
|
|
by lelandfe
1547 days ago
|
|
> yet I find this post misleading. The examples shown are ways NOT to do frontend performance Is advice different than what you prefer "misleading?" Anyway, he doesn't actually weigh in on marking JS with `defer` or `async`. And the article is directly contesting preloading the styles, given his note on race conditions with `media` switching. Moving the CSS before the `</body>` closing tag is genuinely a way to really defer your CSS. > Why would we ever put non-Critical CSS in the <head> in the first place?! To this point from Harry, I find myself skeptical that anyone's really going to want to do that. Getting layout jank / cumulative layout shift fixed when the main stylesheet is applied is a sisyphean task. |
|
I have not run into layout janks when I have used critical path CSS. I'd look into other tools/settings while extracting the critical path CSS if this would happen to me.