Jump to content

Defer loading of the google's javascripts


Recommended Posts

Not sure about shindig, that must be coming from a module.

 

Jquery path is defined in the Media class in the function getJqueryPath()

 

Looking at that function it seems that if you delete the file from your server, Prestashop will automatically try to get it from ajax.googleapis.com

  • Like 1
Link to comment
Share on other sites

jquery is a default library for prestashop and it's defined in frontcontroller,

google library is probably a part of external (non-default) module related to google+ that you use.

it can be also loaded from some browser plugin that you use.

  • Like 1
Link to comment
Share on other sites

Not sure about shindig, that must be coming from a module.

 

Jquery path is defined in the Media class in the function getJqueryPath()

 

Looking at that function it seems that if you delete the file from your server, Prestashop will automatically try to get it from ajax.googleapis.com

I don't want to delete it just to defer its loading using the minify library.

But if PS is loading it from local instead of calling it with the <script> tag it might not work.

Edited by Rho_bur (see edit history)
Link to comment
Share on other sites

  • 2 months later...

I don't want to delete it just to defer its loading using the minify library.

But if PS is loading it from local instead of calling it with the <script> tag it might not work.

 

I think you will very interested in this  moudle:

http://www.prestashop.com/forums/topic/314461-module-prestashop-javapro-remove-page-render-blocking-javascripts/

 

you can load specific which java is loaded at the bottom with optional advanced html attributes defer or async. (when not using optional ccc bottom java).

Link to comment
Share on other sites

  • 8 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...