futtta / ao_critcss_aas

Autoptimize power-up to integrate with criticalcss.com
9 stars 1 forks source link

(option to) disable CCSS injection for logged in users #48

Closed futtta closed 6 years ago

futtta commented 6 years ago

as:

shouldn't we simply not inject CCSS for logged on users?

disadvantage; users might claim it doesn't work, as they would not see the CCSS when doing view-source in their active browser-session (they would need switch to a different browser/ private session).

pocketjoso commented 6 years ago

Imo let's just explain that they should check the site logged out to see it with critical css. (unless they change this setting - at their own responsibility)

futtta commented 6 years ago

the question is; for how many users does the CCSS break the logged in pages even after the full CSS has loaded. this should be a small percentage.

and if it doesn't break final rendering, then having the CCSS in place does allow for faster rendering of the page (albeit without the elements that are for logged-in users only.

because if we disable CCSS for logged in users by default, we're making it useless for all sites that allow users to log in (eshops, bbpress, buddypress, ....)

On Fri, Jul 20, 2018 at 3:01 PM, Jonas Ohlsson Aden < notifications@github.com> wrote:

Imo let's just explain that they should check the site logged out to see it with critical css. (unless they change this setting - at their own responsibility)

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/futtta/ao_critcss_aas/issues/48#issuecomment-406593905, or mute the thread https://github.com/notifications/unsubscribe-auth/AALEMZZ9AfczHceqja2oEl1FihAgK2PUks5uIdStgaJpZM4VX3rk .

pocketjoso commented 6 years ago

the question is; for how many users does the CCSS break the logged in pages even after the full CSS has loaded. this should be a small percentage.

It's not enough that the full render fixes it, if it's broken at the first render it's a no-go.

and if it doesn't break final rendering, then having the CCSS in place does allow for faster rendering of the page (albeit without the elements that are for logged-in users only.

Only if the full css is not cached. Which it should be after the first visit. Yes, there are definitively cases where a logged in user returns later, and the css they have cached is no longer the latest.. but it's not worth breaking pages just to support this use case. Critical css is really primarily meant for the first visit, which will always be on logged out pages.