Re:Numeral.js – A JavaScript library for formatting and mani...
by felxh on Tuesday May 27, 2014 @02:54AM
(#7803240)
Thanks, I learned something new! But yeah, as other people have pointed out, browser support starts with IE 11 and almost no mobile browser supports it - so it might as well not exist.
Re:Numeral.js – A JavaScript library for formatting and mani...
by clarkdave on Tuesday May 27, 2014 @04:57AM
(#7803550)
Intl is rather excellent, and if you do want to use it there's an nice shim for it here: https://github.com/andyearnshaw/Intl.js
I've been using this with great results so far. It works well with a loader (e.g. yepnope) as Chrome and Firefox support it natively, as does IE11.
Re:Numeral.js – A JavaScript library for formatting and mani...
by inglor on Tuesday May 27, 2014 @10:06AM
(#7804526)
Thanks for the shim, I was looking for that - very useful and passes all my tests in IE10.
Re:Numeral.js – A JavaScript library for formatting and mani...
by johncoltrane on Tuesday May 27, 2014 @02:51AM
(#7803233)
That's probably because most developers care about compatibility.
Re:Numeral.js – A JavaScript library for formatting and mani...
by Gmo on Tuesday May 27, 2014 @06:07AM
(#7803705)
Surely, you mean, most developers only care about compatibility with Chrome ?
Re:Numeral.js – A JavaScript library for formatting and mani...
by johncoltrane on Tuesday May 27, 2014 @07:48AM
(#7803934)
You raise an interesting point: if we were the only ones in charge I'd say that a sizable proportion of us, developers, would target Chrome and only Chrome. But we unfortunately have to deal with functional specs and project managers and "clients" (whatever that is) and older browsers that force us to think in compatibility terms rather than coolness terms.
Re:Numeral.js – A JavaScript library for formatting and mani...
by Gmo on Tuesday May 27, 2014 @11:02AM
(#7804820)
I work for a company where we still have customers using IE 7, so I know what you mean.
But no, I don't want to develop only for Chrome, and these days, you see a lot of that happening on "cool tech", even when there is the equivalent in, at least, Firefox.
Re:Numeral.js – A JavaScript library for formatting and mani...
by inglor on Tuesday May 27, 2014 @10:05AM
(#7804519)
With shimmable APIs?
Re:Numeral.js – A JavaScript library for formatting and mani...
by double051 on Tuesday May 27, 2014 @01:50AM
(#7803103)
I didn't know about that until now. Here's a neat blog post on the subject - http://marcoscaceres.github.io/jsi18n/
That said, numeral.js doesn't look like just subset, it's got a nice interface to work with, and you don't have to worry about cross-browser inconsistency. You just have to believe this library does everything correctly for each language/locale.
Still, nice effort! I like it