Choices: What does lightweight mean?

Created on 26 Mar 2020  路  6Comments  路  Source: Choices-js/Choices

Looking in the readme it says

Lightweight

I thought this was about filesize. Though comparing

choices.min.js 73.8 kb
select2.full.min.js 79.2 kb
select2.min.js 70.9 kb

Different jQuery implementations https://github.com/kenwheeler/cash#comparison with partial builds https://github.com/kenwheeler/cash/blob/master/docs/partial_builds.md#size-comparison

bug

All 6 comments

I don't want to add this "bug" label, sorry for that.

Where do you get the 73.8kb from? As it is only 18.7 kb from the CDN, that is why it is Lightweight

Go here https://github.com/jshjohnson/Choices/releases

Click Source code

Browse to: public/assets/scripts/choices.min.js

I don't understand, how can the CDN be 18.7kb ? which file is that version??

choices.min.js 73.8 kb
select2.full.min.js 79.2 kb

This is not a like for like comparison - select2 will not work without jQuery which itself is 82.34 KB, Choices will.

The 18.7kb size is the gzipped file (i.e. the compressed minified file) which the CDN serves.

Well if "lightweight" can't be compared, i don't see how it can be quantified. Seems a bit of empty term then to me.

select2 will not work without jQuery

Have you tested Select2 with zepto.js or cash.js ?? I doubt that this statement is true.

Have you tested Select2 with zepto.js or cash.js ?? I doubt that this statement is true.

Either way you're forced to use another library in addition to it ergo it's larger than just the file size alone.

How "lightweight" this library is can be compared, you just have to have a level playing field. If you think that's an empty term, that's cool though 馃憤

Was this page helpful?
0 / 5 - 0 ratings