Defer parsing of JavaScript
Author: Gevorg Mkhitayan
Visited 2815,
Followers 1,
Shared 0
I have created a website (temporary it is here: lusamdesign.vshosting.0lx.net) with a list of more than 7000 products and it takes a lot of time to load the page, as x5cart.js is about 4mb (with gzip enabled about 600kb). Google suggests "Defer parsing of JavaScript", which means you can put some scripted element in the head of the webpage to load javascript after loading of other resources is finished. In Websitex5 it's possible to put such script in <HEAD>, but it appears after the other scripts. So is there a way to add such code to reduce time of loading? If no, I suggest to give users opportunity to use such scripts, which will be very helpful for a E-commerce websites with a huge list of products. Regards
Posted on the
Hello Gevorg,
You can add the code once you exported the project in the header before the other scripts.
It cannot be done inside WebSite X5. You can choose if you want to export it locally, modify it and then use an FTP Program tu upload it or you upload it on the server and then you login in the ftp and you edit the file.
If you require any further information, please feel free to write back.