On Fri, Jul 6, 2012 at 3:35 AM, Jussi Kalliokoski
<[email protected]> wrote:
> Hahah, sweet, but it doesn't make it faster to type needed at all! Quite the
> opposite even, it requires more thinking. ;)
>
> But maybe I'll just add yet another function to my boilerplate:
>
> function createArray (l, cb) {
>     return Array.apply(null, new Array(l))
>         .map(Function.call.bind(Number))
>         .map(cb)
> }

If you're hiding it behind a function abstraction, there's absolutely
no need to carry over that obtuse functional paradigm.  Just put a
for-loop in that function and be efficient.

~TJ
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to