Message from JavaScript discussions
August 2017
— I always get into rants about jQuery but I think the #1 issue is... How much do you actually need it? Like, literally how big is your project and what is the actual number/percentage of uses of the library. 99% of the time I see very few uses of it, even in something as complex as a template engine... In the end you can easily use the DOM API itself with just as much complexity, or write a tiny spattering of kitchen sink functions
If you could include
like in C++ or Java, like
include "jquery::sizzle"
that would be neat and solve the bloat issue imo
— Bare minimum you need jQuery object wrapper and Sizzle
— You can actually if jQuery is rewritten in that way
— Like with webpack and native javascript modules?
— There are jQuery like libs with that functionality
— I haven't seen source code of jQuery
— Yes, if function/class is exported,import 'functionNameOrClass' from 'module'
— You build it in a web portal, then it bundles only parts of the lib you need... Actually I am wondering if jQuery already has that somewhere
— An issue should be created for it on github, seems a nice idea
— Heh, lodash works this way
— Maybe jQuery is highly coupled thats why not possible in jQuery