Google Speed Test Errors

kdb

Active Member
Is there a way to fix these issue as google said.

"Ensure text remains visible during webfont load"
/wp-content/themes/raphael/assets/fonts/ProximaNova-Semibold.woff
"Avoid chaining critical requests"
/wp-content/themes/raphael/assets/fonts/ProximaNova-Semibold.woff
"Avoid an excessive DOM size"
Statistic Element Value
Total DOM Elements 2,111
Maximum DOM Depth <img src=""> 16
Maximum Child Elements <div class="a2a_full_services"
id="a2apage_full_services"
role="presentation"> 98
 
Last edited:
E

Ekaterina Sayapina

Guest
Is there a way to fix these issue as google said.

"Ensure text remains visible during webfont load"
/wp-content/themes/raphael/assets/fonts/ProximaNova-Semibold.woff
"Avoid chaining critical requests"
/wp-content/themes/raphael/assets/fonts/ProximaNova-Semibold.woff
"Avoid an excessive DOM size"
Statistic Element Value
Total DOM Elements 2,111
Maximum DOM Depth <img src=""> 16
Maximum Child Elements <div class="a2a_full_services"
id="a2apage_full_services"
role="presentation"> 98
Hello,

Thanks for bringing this to our attention!
We'll optimize font loading in the next theme update.
 
  • Like
Reactions: kdb

chris37

Well-Known Member
Hi Ekaterina,

It is same with smart theme woo. Is there any fix with the latest update?

Thx.
Cache plugin.
CDN
Autoptimize plugin .
Lazy load
Smush image
"Manual smush image " ;)
Delete the themes and plugin you don't use .
Get a better hosting.

Choose one or make all of them :)
 
You don't have to worry so much about google pagespeed as your site goes fast by itself. There are many factors that can cause your page to go slow. We have most of the problem in the lack of configuration of the hosting and in a bad configuration of wordpress. If you are worried about having a good score in the pagespeed, I recommend that you put a service like nitropack, in a moment it will do magic for you, it will configure your site and you will have all the score to more than 90 on desktop and mobile.
However, if what you are concerned about is that the page is 100% functional and go like lightning ... your concern is to have a good configuration both in the hosting and in wordpress. The first thing I would do is completely rule out shared hosting, since it will only give you problems. If that is not your case and you have a server for you, it is to check that you have Nginx installed and configured. It is important, because the PHP load is constant and does not interrupt or call like Apache. The second step is to install and configure on your Redis server. Thus the database load, caching, session management, pub / sub and it will distribute the load a lot (you will have to configure it in the hosting and in wordpress).
Once you have your host ready, as Chris37 said very well, we would start with autooptimize, cdn, some OPcache plugin and image optimizer.

P.D. If you want to eliminate google fonts, with a small code in the functions.php of the active theme you can completely deactivate the loading of Google Fonts, even if they are “called” from the web layout.

add_filter( 'style_loader_src', function($href){
if(strpos($href, "//fonts.googleapis.com/") === false) {
return $href;
}
return false;
});

You can also asynchronize them so that the load is asynchronous.
You must insert this script in the header of the website, between the <head> </head> tags of the active theme, or through a plugin to put scripts in the header:

<script type="text/javascript">
WebFontConfig = {
google: { families: [ 'Noto+Serif:400,400italic,700,700italic' ] } // Example
};
(function() {
var wf = document.createElement('script');
wf.src = 'https://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js';
wf.type = 'text/javascript';
wf.async = 'true';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(wf, s);
})();
</script>

Remember that you must customize it with the fonts that you use right where in the code it says the comment "Example". Otherwise, the code will not work.
 
Last edited:

chris37

Well-Known Member
P.D. If you want to eliminate google fonts, with a small code in the functions.php of the active theme you can completely deactivate the loading of Google Fonts, even if they are “called” from the web layout.

add_filter( 'style_loader_src', function($href){
if(strpos($href, "//fonts.googleapis.com/") === false) {
return $href;
}
return false;
});

No need for the code, the autoptimize plugin can do that . (i personal combine and link in head)

Screenshot 2021-04-11 at 10.27.09 PM.png
 
No es necesario el código, el complemento de optimización automática puede hacer eso. (Yo personal combino y vinculo en la cabeza)

[ATTACH = full] 14512 [/ ATTACH]
Es correcto, pero dependiendo del tema puede bloquear la carga de la página. No todo el mundo lo está haciendo bien.
 

erdinc

New Member
Thanks for the quick reply. I tried both. Nitropack is like a magic for the speed result but the theme has been broken so i deactivate it. Autoptimize is fine but the font settings is not working for me (I tried both section). I think the site runs fine and speed test is not my concern anymore at this moment.

Thank you very much
 

chris37

Well-Known Member
Thanks for the quick reply. I tried both. Nitropack is like a magic for the speed result but the theme has been broken so i deactivate it. Autoptimize is fine but the font settings is not working for me (I tried both section). I think the site runs fine and speed test is not my concern anymore at this moment.

Thank you very much
If you really want to see the difference, invest money on cloud hosting or a dedicated server .

I just don't think for one simple website you really going to need it.
 
Top