Skip to Content Skip to Menu

🕒 Save Time and Effort with CB Editor Assistant: Effortlessly create and refine content in Joomla 3, 4, & 5.
🎁 Limited Offer: Enjoy a 5-day FREE trial and save up to 30% afterward!

Disable JQuery

  • ducks_mrd
  • ducks_mrd
  • OFFLINE
  • Posts: 17
  • Thanks: 0
  • Karma: 0
11 years 7 months ago #228530 by ducks_mrd
Disable JQuery was created by ducks_mrd
Good Evening,

I was just wondering if it is possible to disable Community Builder from loading it's own copy of JQuery so that it uses an already loaded copy?

I know there is currently no setting that will do this but this is more of a suggestion.

At the minute both joomla and community builder load your own copies of JQuery and it's UI which just increases the number of http requests.

Also the request to load the community builder copy of JQuery gets a parameter "v" added with a random value. Is there any reason why this gets added as this means this file does not get cached, this then just adds to the above.

I don't know what everyone else thinks but how about loading a copy from a CDN if it fails then fall back to a single local copy.

On my site I load JQuery from the Google CDN, and Bootstrap from BootstrapCDN.
I also load Font Awesome via the Bootstrap CDN.

Which then fails back to local copies.

Using the CDN also gives smaller file sizes and speeds up other sites that also request the same CDN file as you already have it cached.

Just wondered what your thoughts would be as I think this would be a great addition to Community Builder and Joomla in general.

Kind Regards

Mike

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48700
  • Thanks: 8317
  • Karma: 1447
11 years 7 months ago #228531 by krileon
Replied by krileon on topic Disable JQuery
No, CB uses a specific version of jQuery because we have yet to update all of our usages to meet the latest releases needs. Latest releases of jQuery have dropped backwards compatibility for a lot of usages which would cripple CBs jQuery. CB also runs its jQuery in a deep noConflict usage, which gives it its own namespace. This mans CBs jQuery should be fine running alongside another version of jQuery without conflict.

CDNs are not a good idea. You're loading an external library so you're limited to the speed of their servers. If their servers go down or slow down it affects you. Always run your own local copies for best speed. CDN will never be faster than local copies. You can also compress files manually by using the below site if you need files to be smaller.

refresh-sf.com/yui/

Realistically none of this particularly matters speed wise anymore. Most are on high speed connections of at least 1mb/sec and won't notice a few KB CSS/JS files loading in. In addition to that once they do load in they become browser cached on the clients computer so subsequent loadings will be quicker.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum