artursapek / mondrian

Web-based vector graphics editor
MIT License
1.24k stars 104 forks source link

Drop dependence on jQuery? #27

Open artursapek opened 10 years ago

artursapek commented 10 years ago

I'm not sure whether we should be trying to remove jQuery. Grepping around, it looks like there's ~400 instances of jQuery methods being used.

http://artur.co/pastes/1390824908.txt

That's a lot. It would take a while to replace, and doing so might be a waste of time.

If we don't remove it, we could use a CDN like Google to serve jQuery instead and get more or less the same speed benefit.

Fishrock123 commented 10 years ago

CDN / Custom-built jQuery (if we aren't using much of its features) is a good start.

waldyrious commented 10 years ago

For reference, here are some links that may be useful for such a transition:

Fishrock123 commented 10 years ago

(I recently did a lot of work on a project that used no jQuery or similar libs, I can take this up if need be.)

artursapek commented 10 years ago

Nah, this isn't a priority. Let's leave it alone for now.

There are several bugs open right now that are more important to tackle.

tomByrer commented 10 years ago

There is a new library that has many jQuery DOM & event functions. Focuses on evergreen browser compatibility, so is around 2x+ faster than even Zepto & smaller. http://webpro.github.io/jquery-evergreen/ No AJAX, but that is easily replaceable by another micro-library. show() & hide() are the frequent missing functions.

artursapek commented 10 years ago

Hmm. Mondrian uses a few functions like closest and val that this doesn't seem to support. Interesting lib though.