DEV Community

Discussion on: How to score 100 on Google PageSpeed Insights on Mobile

Collapse
 
grahamthedev profile image
GrahamTheDev • Edited

You can’t load the menu “on intent”.

Just tried it on 4G, took over 3 seconds to open the menu.

Instead you should just inline some minimal JS for anything above the fold and then lazy load everything else required for the page to run.

This was always my concern with Qwik as your site loads fast other than that.

In the real world you First Input Delay (FID) is going to skyrocket as it stands and destroy your web vitals.

This is where the synthetic tests can mislead unfortunately. I would recommend github.com/GoogleChrome/web-vitals and pipe it to either analytics or build your own mini API so you can fine tune the data while testing so you can preempt issues like this one using Real User Metrics.

Collapse
 
mhevery profile image
Miško Hevery • Edited

3 seconds sounds way to long, I think you must have gotten lucky and hit a CDN miss as the URL is not heavily used yet.

But what is still not integrated is prefetching of resources, which will make this concern go away. That is coming next using Web-Workers so it will not affect the web-vital score and ensure that all resources are ready to use as soon as they are needed.