Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

JQuery: how to download ONLY necessary components?

Tags:

jquery

I simply want to use the JQuery Slider functionality and nothing else.

However, to do so - it's my understnading that I must download 3 files:

  1. JQuery Core
  2. JQuery UI base
  3. JQuery Slider

This totals to about 74kb (28kb gzipped).

Since I'm ONLY using JQuery for the Slider functionality - how can I remove all the unused JQuery base code like the Toggle function, etc easily?

like image 678
Hank Avatar asked Jan 23 '23 01:01

Hank


1 Answers

Not easily.

Minified gzipped jQuery is only 19KB; it's not worth the effort.

For added performance, load jQuery.js from Google: http://ajax.googleapis.com/ajax/libs/jquery/1.3/jquery.min.js

like image 52
SLaks Avatar answered Feb 03 '23 19:02

SLaks