Last active
August 29, 2015 14:22
-
-
Save aaronshaf/e75f3785e9c72122b5e2 to your computer and use it in GitHub Desktop.
Wouldn't partials here be better than virtual methods?
This file contains hidden or 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
// ES7 | |
getPlayers() | |
::map(x => x.character()) | |
// ES6 | |
let _val | |
_val = getPlayers() | |
_val = map(_val, x => x.character()) |
This file contains hidden or 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
// ES7 | |
getPlayers() | |
::map(x => x.character()) | |
// ES6 | |
let _val | |
_val = getPlayers() | |
_val = map.call(_val, x => x.character()) | |
// See https://github.com/gsklee/bound-native-methods and http://babeljs.io/blog/2015/05/14/function-bind/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment