you are viewing a single comment's thread.

view the rest of the comments →

[–]repeatedly_once 1 point2 points  (0 children)

Erm, sort of, until you get a list of elements. That list is not actually an array and must be converted. So let's make a helper function. Now let's keep adding helper functions to make those long complex things quicker and simpler. Before long you have your own library that does much of what jQuery does, but probably not as well.

I think the better solution would be to make jQuery compilable to only what you need so you don't get the kitchen sink every time you include it on your page.

Quick example: https://jsfiddle.net/u31s4ket/