Minify JS and CSS
Moderator: General Support Moderators
Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
-
- Joomla! Apprentice
- Posts: 34
- Joined: Sun Apr 29, 2018 4:40 pm
Minify JS and CSS
Hi,
In the Joomla admin backend - I have enabled - Optimize CSS & JS - http://prntscr.com/ozj82r
However, as per https://gtmetrix.com/ - it is still suggesting to enable / minify jss and css.
So, please let me know - how to proceed ahead with it.
Regards.
In the Joomla admin backend - I have enabled - Optimize CSS & JS - http://prntscr.com/ozj82r
However, as per https://gtmetrix.com/ - it is still suggesting to enable / minify jss and css.
So, please let me know - how to proceed ahead with it.
Regards.
- bruno28
- Joomla! Guru
- Posts: 536
- Joined: Wed May 16, 2012 5:41 am
- Location: Chartres, France
- Contact:
Re: Minify JS and CSS
Hello AnandGIBES005
Did you clear the Joomla cache and your browser cache ?
Did you clear the Joomla cache and your browser cache ?
-
- Joomla! Champion
- Posts: 5932
- Joined: Tue Aug 23, 2005 1:56 pm
- Location: South coast, UK
- Contact:
Re: Minify JS and CSS
The gmetrix site offers you the option to download minified css and js.download and replace on your site.
https://gadsolutions.biz Electrical services
https://electrical-testing-safety.co.uk Testing services
https://electrical-testing-safety.co.uk Testing services
-
- Joomla! Apprentice
- Posts: 34
- Joined: Sun Apr 29, 2018 4:40 pm
Re: Minify JS and CSS
Yes, I have cleared the Joomla cache and your browser cache and it is still showing - http://prntscr.com/ozl4ve
As you have mentioned - http://prntscr.com/ozl58h
can you please share the url so that I can download it.
As you have mentioned - http://prntscr.com/ozl58h
can you please share the url so that I can download it.
- bruno28
- Joomla! Guru
- Posts: 536
- Joined: Wed May 16, 2012 5:41 am
- Location: Chartres, France
- Contact:
Re: Minify JS and CSS
GTmetrix propose you to download minified css and js as gws said on the right of the files with optimized version
And if you want to cite a post, use the cite button above the message instead of doing screenshot, it's easier
And if you want to cite a post, use the cite button above the message instead of doing screenshot, it's easier
You do not have the required permissions to view the files attached to this post.
- john-doe
- Joomla! Ace
- Posts: 1008
- Joined: Tue Apr 19, 2011 7:39 pm
- Location: Colombia
- Contact:
Re: Minify JS and CSS
I'm sorry it this looks like Hijacking but i'm curious about, Is there any plugin that renders the CSS and JS files, minifies them and when you need to edit them via template editor of the backend get straightened so you can edit your file and once saved gets minified for such services.
I know about that since I know that Typo3 CMS has something close to it but i never heard of it for Joomla. Because that might be a solution for this case.
I know about that since I know that Typo3 CMS has something close to it but i never heard of it for Joomla. Because that might be a solution for this case.
www.aldemar-hernandez.com - Custom templates and design services.
- bruno28
- Joomla! Guru
- Posts: 536
- Joined: Wed May 16, 2012 5:41 am
- Location: Chartres, France
- Contact:
Re: Minify JS and CSS
Maybe JCH Optimize ?john-doe wrote: ↑Fri Aug 30, 2019 4:50 pmI'm sorry it this looks like Hijacking but i'm curious about, Is there any plugin that renders the CSS and JS files, minifies them and when you need to edit them via template editor of the backend get straightened so you can edit your file and once saved gets minified for such services.
I know about that since I know that Typo3 CMS has something close to it but i never heard of it for Joomla. Because that might be a solution for this case.
-
- Joomla! Intern
- Posts: 65
- Joined: Thu Apr 25, 2013 4:05 am
Re: Minify JS and CSS
AnandGIBES005
Can you tell me where to find "Optimize CSS" and "Optimize JS". I do not find either in my Joomla Backup. I am using Ver. 3.9 with the Protostar template.
Can you tell me where to find "Optimize CSS" and "Optimize JS". I do not find either in my Joomla Backup. I am using Ver. 3.9 with the Protostar template.
-
- Joomla! Champion
- Posts: 5932
- Joined: Tue Aug 23, 2005 1:56 pm
- Location: South coast, UK
- Contact:
Re: Minify JS and CSS
See bruno28 second post.Jim Holloman wrote: ↑Fri Sep 20, 2019 6:12 amAnandGIBES005
Can you tell me where to find "Optimize CSS" and "Optimize JS". I do not find either in my Joomla Backup. I am using Ver. 3.9 with the Protostar template.
https://gadsolutions.biz Electrical services
https://electrical-testing-safety.co.uk Testing services
https://electrical-testing-safety.co.uk Testing services
- bruno28
- Joomla! Guru
- Posts: 536
- Joined: Wed May 16, 2012 5:41 am
- Location: Chartres, France
- Contact:
Re: Minify JS and CSS
In the Joomla admin backend - I have enabled - Optimize CSS & JS - http://prntscr.com/ozj82r
Hello Jim HollomanJim Holloman wrote: ↑Fri Sep 20, 2019 6:12 amAnandGIBES005
Can you tell me where to find "Optimize CSS" and "Optimize JS". I do not find either in my Joomla Backup. I am using Ver. 3.9 with the Protostar template.
I think it is not with Joomla but with his template he could do this
-
- Joomla! Intern
- Posts: 65
- Joined: Thu Apr 25, 2013 4:05 am
Re: Minify JS and CSS
I found an extension that is closely related:
https://extensions.joomla.org/extension/jch-optimize/
https://extensions.joomla.org/extension/jch-optimize/
-
- Joomla! Enthusiast
- Posts: 154
- Joined: Sat Sep 21, 2019 7:29 pm
- Contact:
Re: Minify JS and CSS
We regularly use JCH Optimize. It's a great Extension for optimizing css and js files.
It can be difficult to minimize files NOT hosted on your server like the Google Fonts css file. You could download that css file, optimize it and then save it to your server. That would also require relinking to the file on your server instead of Googles file.
I'd use JCH Optimize and just live with whatever limitations you get.
You already have an "A" for PageSpeed which is really good!
It can be difficult to minimize files NOT hosted on your server like the Google Fonts css file. You could download that css file, optimize it and then save it to your server. That would also require relinking to the file on your server instead of Googles file.
I'd use JCH Optimize and just live with whatever limitations you get.
You already have an "A" for PageSpeed which is really good!
-
- Joomla! Apprentice
- Posts: 34
- Joined: Sun Apr 29, 2018 4:40 pm
Re: Minify JS and CSS
I tried to subscribe to JCH optimize their JMSuper Plan but it is showing an error - http://prntscr.com/pny5qkhelpwithjoomla wrote: ↑Sat Sep 21, 2019 7:58 pmWe regularly use JCH Optimize. It's a great Extension for optimizing css and js files.
As mentioned in the error message to try again to subscribe and I did that and again I got the same error message.
I have also sent them this query on their site contact us form - http://prntscr.com/pny70g - but I havent received any reply from their end.
So, please let me know - how to subscribe to it.
Regards.
-
- Joomla! Enthusiast
- Posts: 154
- Joined: Sat Sep 21, 2019 7:29 pm
- Contact:
Re: Minify JS and CSS
That's an issue with the JCH Optimize web site. They will have to assist you to resolve that issue.
Joomla Developers Available To Help With Joomla!
https://www.helpwithjoomla.com
https://www.helpwithjoomla.com
-
- I've been banned!
- Posts: 13639
- Joined: Sun Jul 05, 2009 3:30 am
- Location: Canberra, Australia
Re: Minify JS and CSS
This is a general comment and it reflects only my personal view.
Have you every wondered why more experienced members—i.e. people who have posted more than 1000 messages—of the forum community do not usually reply to questions about third-party extensions that claim to aggregate/"optimise"/obfuscate or minify JS and CSS on-the-fly? It is not because these extensions do not do what they claim to do. It is also not because more experienced members of this community dispute the "value" in minifying JS or CSS.
This topic was posted in the Performance - Joomla! 3.x. When we discuss performance, are we talking about the processing overhead involved at the server or the perceived "performance" of a website when viewed by the end user? If we're discussing the server overheads, then every plugin, every extra module, every additional piece of PHP that's used to create the HTML adds to the processing "performance". If we're talking about the "performance" of a website as perceived by the end user, there are all sorts of factors involved in that: e.g. what else is the end-user's device doing at the time, network capacity, browser capabilities, etc.
Yes, there are benefits in using minified JS and CSS. I don't think anyone would dispute that. The ways in which JS and CSS is minified, however, is an entirely different discussion. There's a cost in "performance" if JS and CSS is minified on-the-fly and while that cost may not be perceptible to the end-user, these so-called "metrics monitors" only draw part of the overall picture. In the end, it's the site owner who must decide for themselves whether the cost in "optimising" the HTML package is worth the effort put into doing it.
Lastly, do I, personally, use JCH_Optimize? The answer is irrelevant: we're not discussing my website(s) but, for the sake of complete disclosure, I don't use it.
Have you every wondered why more experienced members—i.e. people who have posted more than 1000 messages—of the forum community do not usually reply to questions about third-party extensions that claim to aggregate/"optimise"/obfuscate or minify JS and CSS on-the-fly? It is not because these extensions do not do what they claim to do. It is also not because more experienced members of this community dispute the "value" in minifying JS or CSS.
This topic was posted in the Performance - Joomla! 3.x. When we discuss performance, are we talking about the processing overhead involved at the server or the perceived "performance" of a website when viewed by the end user? If we're discussing the server overheads, then every plugin, every extra module, every additional piece of PHP that's used to create the HTML adds to the processing "performance". If we're talking about the "performance" of a website as perceived by the end user, there are all sorts of factors involved in that: e.g. what else is the end-user's device doing at the time, network capacity, browser capabilities, etc.
Yes, there are benefits in using minified JS and CSS. I don't think anyone would dispute that. The ways in which JS and CSS is minified, however, is an entirely different discussion. There's a cost in "performance" if JS and CSS is minified on-the-fly and while that cost may not be perceptible to the end-user, these so-called "metrics monitors" only draw part of the overall picture. In the end, it's the site owner who must decide for themselves whether the cost in "optimising" the HTML package is worth the effort put into doing it.
Lastly, do I, personally, use JCH_Optimize? The answer is irrelevant: we're not discussing my website(s) but, for the sake of complete disclosure, I don't use it.
-
- Joomla! Enthusiast
- Posts: 154
- Joined: Sat Sep 21, 2019 7:29 pm
- Contact:
Re: Minify JS and CSS
Excellent comments sozzled!
I agree with all your points.
When using a tool like Google's PageSpeed or GTMetrix, optimizing css and js is recommended. Thus I think many people want to undertake the optimization. And if organic rankings is important to a person, then you want to do as much as possible to "please" google.
Extensions like JCH Optimize may not be an ideal technical solution, but they are a good option for someone at the novice level.
css and js files can, of course, be manually optimized thus removing the need for those options in JCH. But manual optimization has it's own issues. I usually only do that for sites with content and layout that rarely changes.
Ultimately this posted started with a question about optimizing js and css as suggested by GTMetrix.
We've all just been supplying options.
I would rather reply and give a person an option rather than just not replying at all.
Every user must make their own decisions about how best to proceed.
I agree with all your points.
When using a tool like Google's PageSpeed or GTMetrix, optimizing css and js is recommended. Thus I think many people want to undertake the optimization. And if organic rankings is important to a person, then you want to do as much as possible to "please" google.
Extensions like JCH Optimize may not be an ideal technical solution, but they are a good option for someone at the novice level.
css and js files can, of course, be manually optimized thus removing the need for those options in JCH. But manual optimization has it's own issues. I usually only do that for sites with content and layout that rarely changes.
Ultimately this posted started with a question about optimizing js and css as suggested by GTMetrix.
We've all just been supplying options.
I would rather reply and give a person an option rather than just not replying at all.
Every user must make their own decisions about how best to proceed.
Joomla Developers Available To Help With Joomla!
https://www.helpwithjoomla.com
https://www.helpwithjoomla.com
-
- I've been banned!
- Posts: 13639
- Joined: Sun Jul 05, 2009 3:30 am
- Location: Canberra, Australia
Re: Minify JS and CSS
Thank you for your reply, @helpwithjoomla. I agree that, for novice users, CSS and JS aggregation solutions may be useful but there can be unintended consequences in using third-party aggregators (e.g. JCH_Optimize). That's not why I was offering my opinion.
As I wrote, this topic was posted in the Performance - Joomla! 3.x forum category and it's important to understand what kind of "performance" we're discussing. Obviously, a website that downloads a hundred images in the HTML package will not perform as well as a one-page website that contains mostly text. Regardless of whether that "text" involves the use of JS or CSS, performance analysers such as the ones you've mentioned will report different conclusions.
In the end, the effort involved in achieving an "A" result may outweigh the value of the website's usefulness to the end-user. It stands to reason that, if the end-user has to wait more than a few seconds before the website's page is displayed, the end-user will probably give up and go somewhere else. In situations where a website produces Mbytes of data that has to be trafficked to its users, CSS and JS optimisation is at the tail end and such tools rarely result in more than a few percent improvement in overall performance.
Every website is different. Everyone's measure of "performance" is probably different, too. Beyond that, I can't say much else. Cheers.
As I wrote, this topic was posted in the Performance - Joomla! 3.x forum category and it's important to understand what kind of "performance" we're discussing. Obviously, a website that downloads a hundred images in the HTML package will not perform as well as a one-page website that contains mostly text. Regardless of whether that "text" involves the use of JS or CSS, performance analysers such as the ones you've mentioned will report different conclusions.
In the end, the effort involved in achieving an "A" result may outweigh the value of the website's usefulness to the end-user. It stands to reason that, if the end-user has to wait more than a few seconds before the website's page is displayed, the end-user will probably give up and go somewhere else. In situations where a website produces Mbytes of data that has to be trafficked to its users, CSS and JS optimisation is at the tail end and such tools rarely result in more than a few percent improvement in overall performance.
Every website is different. Everyone's measure of "performance" is probably different, too. Beyond that, I can't say much else. Cheers.