2kb JQuery for animated list in circle
playground.mobily.pl
playground.mobily.pl
This stuff works on the web, right? A demo is the first thing anyone should see when visiting your project.
E.g. see my http://chir.ag/projects/drop-search/ project demo on: http://chir.ag/projects/drop-search/demo.shtml vs http://chir.ag/ - the search works throughout my site but it's very easy to see how to implement it on the simple demo page.
But what if later on you want to upgrade the framework on your site, but it breaks the demo and its not worth fixing (for example, you're demoing proof of concept or a little study)? It's easier to keep the demo on its own site where you don't have to worry about conflicts with your main site js.
And sure, you should be keeping everything out of the global scope, but sometimes you have some legacy code, or maybe you don't know exactly how to do that, etc.
Other times it's a limitation of the CMS (You can't include scripts).
You could put it inline on your page, but its easier and less error-prone to toss it on its own page.
But yeah, if you're just making a stand-alone project page, you really shouldn't have the above problems.
Why are there variables called 'social' in the source?!
Also ... seems like it could be packed much smaller. The author should run it through the Closure Compiler. In the least, lots of local variables would be obfuscated.
Also, with such a small code base as that, a minifier like Closure Compiler is pointless. I ran it on http://closure-compiler.appspot.com/home with "Advanced" checked:
Original Size: 2.13KB (940 bytes gzipped)
Compiled Size: 1.28KB (660 bytes gzipped)Nifty effect, but I don't see anything newsworthy about it. Can we stop the fascination with every thing that moves in a browser? DHTML is over a decade old now.
It's not simply that it moves, it's a slick presentation of a very boring element (namely unordered lists).
So that's about 22KB for this effect when most sites already are including jQuery anyway.
I'm actually impressed by this type of UI. Each button is equidistant from the center. This makes it a little bit easier to use for users lacking fine motor control (elderly, disabled, children).
My point is that there's nothing impressive about it:
• it's not novel. Circular UIs are old. DHTML and rounded corners are old.
• it's not some advanced code. Rotating equidistant circles is basic trigonometry, not a rocket science.
• it's not even a clever hack. JS1K contest had whole games in half of the size, without jQuery to help.