Every page loads a js of about 500kb.
Is this right? It seems like quite a big script and I'm unsure what it actually does. Should it be loading from the cache? I'm trying to get website fully optimised. Thanks
That's actually a compiled file of all scripts used by CS-Cart and any active addon. 500kb does indeed seem pretty large (ours is around 220kb). Do you have a lot of addons installed?
Yeah a few, but they seem to have their own scripts loading. It's probably something to do with this awful theme we're using.
You could disable compilation of JS files by changing $config['tweaks']['dev_js'] to true in config.local.php (line #100 in my case). You could then view your page source and look for .js files to see what size the individual file sizes are. This should give you an indication as to what part is causing your compiled JS file to be this huge.
Should be cached by the browser and only donwloaded on 1st access unless you have the "Rebuild cache automatically" setting turned "on". If it's on, all of the "static" files are loaded for every page load so you can make changes without having to clear the cache in between changes. Just go to Design/Themes and in the upper corner, turn it off. I thiink you'll find that it then donwloads once (unless you have done something that modifies it).