By pcx99
via hunlock.com
Published: Mar 05 2007 / 12:47
Javascript frameworks have exploded on the scene over the last few years but they're no replacement for a good toolbox: those little snippets of code you seem to include in every single project. Here's my list of 10 essential Javascript tools everyone should have at their fingertips!
Tweet
SaveShareSend
Tags: how-to, javascript, opinion, web design
Comments
boo_radley replied ago:
#2 on his list has a big flaw: his unformatnumber doesn't handle negative numbers...
>>> num = -4
-4
>>> num.toString().replace(/([^0-9\.])/g,'')*1;
4
pcx99 replied ago:
You know, with my budget the way it is I really should have caught that ;) Fixed! Nice catch :) The un/format functions also blow up on exponents but that's a bit out of the scope of a simple commafier.
boo_radley replied ago:
I thought about that too, but you're never going to see commas in scientific notation, so you get a free pass there :o)
Voters For This Link (22)
Voters Against This Link (0)