8

My website for an enterprise client has approximately 90 assets that download on load, 35 or so are JS files. Even "optimizing" extensions that are made for Joomla only seem to get me down to 31 or so JS files and compress only the combined css/js and not the ones that seem to run rogue.

I've tried a few of the optimizing free plugins, and I'm reluctant to spend money on the paid ones if they're going to do very little for my load times.

My template is a Rockettheme base with a lot of customization, so it has Gantry js, bootstrap js, a couple extensions like my video player use a js file, etc, and they seem to be spread out to a couple per extension instead of just one.

What works and what doesn't for improving this part of front end load?

3 Answers 3

9

It won't be easy to deal with all these files. Combining, minifying and compressing all these together will most probably bring issues. It will take much effort and a combination of techniques to reach a satisfactory optimization level.

My overall Approach to achieve a fast loading site.

A fast website is essential. The speed optimization of a website, although it usually takes places at the end of the development, it is something that should be considered from the beginning. It starts with the proper template.

Also installing each and every extension, and using any kind of fancy modules, it probably result to a heavy website, that will be very hard to make it lighter later on.

Be eclectic - stay minimal

Personally, when it comes to speed optimization, I try to be very eclectic on what extensions I use. I research and experiment for the most efficient and quality ones for each task, and always try to avoid to use any extensions, if there are things that can be achieved manually within the core.

Also, if I have to decide on using a fancy front-end feature not really important, that causes me troubles in speed optimizing the website, I usually will throw it away, or find another way to implement the fancy feature.

I also try to avoid to use commercial templates, since they usually come with many extra features to satisfy many different tastes. I prefer to build the template and include only what I need.

Your Manual Work

I would suggest to review all the extensions you have to see how they load their assets files, and if it's possible to avoid load them in pages where you don't need them, e.g. you could create template overrides where possible to control on your own the loading of the assets files.

You might find that there are extensions that you don't need, but are still loaded, or you don't have the optimum settings on how they should work.
E.g. JCE Mediabox provides option to be loaded only in specific menu items.

Also see if it's possible to merge files in one. E.g. don't let any module to load it's css, try to merge it with the template's css file.

Optimization Tools

CSS/JAVASCRIPT COMPRESSION & CONTROL
As for optimization tools/plugins, I am pretty happy with the JCH Optimize plugin. It's free, but also has a commercial version with support for a few bucks. With the proper tweaking, it can produce great results and the developer is quite helpful if you need support.

Another tool that might be proved useful, is the JQuery Easy plugin. It can help to better organize and control the loading of various javascript files, in the case they conflict with each other and make the optimization with JCH_Optimize Plugin easier.

CACHE
I also use Jot Cache, to have better control over the Cache, since many extensions have issues with the core cache.

CDN
Using CDN to deliver static content is the next tool - I use NoNumber CDN for Joomla

HTACCESS
Finally, big benefits you will gain by using an htaccess to compress and add Expire headers to the files.

5

There is no simple solution for 30+ JS files.

2
  • I clicked the full suggestion above as the "answer" but I must also note that RokBooster worked much better for me than JCH Optimize because I'm using a Gantry based template and extensions. Thank YOU! I wish I could click both.
    – Toni Marie
    Commented Nov 14, 2014 at 19:52
  • Cool, glad to be helpful
    – Anibal
    Commented Nov 16, 2014 at 23:09
0

maybe you can try this free online service to compress javascript http://www.online-code.net/minify-js.html and minify css http://www.online-code.net/minify-css.html, so it will reduce the size of web page. and this tool is free to use, just need you upload your js and css file, you can download the mini file later.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.