Request to Add font-display: swap; in Generic_Plugin.php
-
Dear W3 Total Cache Support Team,
I would like to suggest a small improvement to the
Generic_Plugin.phpfile. Specifically, in theadmin_bar_init()function, I recommend adding the following line:font-display: swap;right below line 441
font-style: normal;in the@font-facerule ofGeneric_Plugin.phpfile. Why this is important:Adding
font-display: swap;ensures that text remains visible using a fallback font until the custom font is fully loaded, improving both perceived performance and user experience. This approach helps avoid the “flash of invisible text” (FOIT), which can negatively impact Core Web Vitals metrics, such as First Contentful Paint (FCP) and Largest Contentful Paint (LCP). These metrics are crucial for Google PageSpeed Insights, and improving them can lead to a better overall performance score.Thank you for considering this suggestion.
Bests,
Lena
You must be logged in to reply to this topic.