Remove Render-Blocking JavaScripts

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
8 years ago
dianoche wrote:
i was guessing the widgets may create some problems :) so they are.


I think some hack can help here. We can intercept widget contents before they are rendered and include delay in all script tags. A small plugin can handle it.

So, once admin's views dont require defer scripts, we could try new approach too, using a "cloned" _root view with fixed scripts included, then the number of views we need to check will decrease a lot.

What do you think?

Ivan.
8 years ago
ivanslater wrote:
i was guessing the widgets may create some problems :) so they are.

I think some hack can help here. We can intercept widget contents before they are rendered and include delay in all script tags. A small plugin can handle it.

So, once admin's views dont require defer scripts, we could try new approach too, using a "cloned" _root view with fixed scripts included, then the number of views we need to check will decrease a lot.

What do you think?

Ivan.


I am not a huge plugin fan but we need to find solution for everyone.If we can do it for google analytics and yandex metrika without interrupting them, why not :)

There are still parts that i didn't understand on eurodress's method. Since he is working on it more than anyone else and tested it, I am sure he has a good solution. I didn't have a chance a try his solution yet. I understood the inline script part.

The only part I didn't understand;

we are changing the generate scripts method in PageHeadBuilder.GenerateScripts. So it is defering all js. how we separate the ones  required for loading the libraries?

When I analyse my page with https://developers.google.com/speed/pagespeed/insights/
all google bots are interest in the scripts we call from _Root.Head with Html.AppendScriptParts and Html.AddScriptParts.
8 years ago
dianoche wrote:

we are changing the generate scripts method in PageHeadBuilder.GenerateScripts. So it is defering all js. how we separate the ones  required for loading the libraries?

I hardcoded that now.

But anyway, it's still buggy, and takes too much time. For other reasons as well I'm now looking into migrating to Prestashop.
8 years ago
eurodress wrote:

For other reasons as well I'm now looking into migrating to Prestashop.


PHP is nothing the solution for anything!
8 years ago
ivanslater wrote:

For other reasons as well I'm now looking into migrating to Prestashop.

PHP is nothing the solution for anything!

Well, it passes the javascript blocking test in Google Pagespeed without any code change. Just enabled a setting, and it worked. 73/87 score on Google Pagespeed!

It has modules for Poli (NZ & AU payment option), nopCommerce does not have.

Sorry guys, but this change just took too long and became too hacky.
8 years ago
eurodress wrote:

Well, it passes the javascript blocking test in Google Pagespeed without any code change. Just enabled a setting, and it worked. 73/87 score on Google Pagespeed!


I believe it and I belive that a lot of another e-commerces do it too. The point is, PHP is an old language with some big problems, security, performance issues.

If you want to find a better solution, you must consider a big list of important requirements.

Thats is it.
8 years ago
eurodress wrote:

For other reasons as well I'm now looking into migrating to Prestashop.

PHP is nothing the solution for anything!
Well, it passes the javascript blocking test in Google Pagespeed without any code change. Just enabled a setting, and it worked. 73/87 score on Google Pagespeed!

It has modules for Poli (NZ & AU payment option), nopCommerce does not have.

Sorry guys, but this change just took too long and became too hacky.


I think there was something else slowing down your speed. Without Remove Render-Blocking JavaScripts/CSS my current speed is 88 and i have a megamenu with category pics on the website. I don't think it is just Nopcommerce.
8 years ago
when i remove the megamenu pics it goes up to 90-91
8 years ago
dianoche wrote:

I think there was something else slowing down your speed. Without Remove Render-Blocking JavaScripts/CSS my current speed is 88 and i have a megamenu with category pics on the website. I don't think it is just Nopcommerce.


True. I got more than 90 with same plugins and issues.
8 years ago
it is out of topic but I sent you a pm Ivan. Did you see that?
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.