Last active
December 11, 2015 17:49
-
-
Save fogus/4637334 to your computer and use it in GitHub Desktop.
All this and more in Lemonad and in fine bookstores and libraries near you!
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ZOMG!! | |
['11','11','11','11'].map(parseInt) | |
//=> [11, NaN, 3, 4] | |
// Fixing JavaScript foibles with delicious curry! | |
['11','11','11','11'].map(curry(parseInt)); | |
//=> [11, 11, 11, 11] | |
// Underscore too | |
_.map(['11','11','11','11'], curry(parseInt)); | |
//=> [11, 11, 11, 11] | |
// http://www.functionaljs.org | |
// http://github.com/fogus/lemonad |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment