32

三行代码实现 JS 柯里化

 5 years ago
source link: https://juejin.im/post/5bf9bb7ff265da616916e816
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
最近有看到一些柯里化的文章,怎么说呢,感觉很奇怪。一篇是阿里云的译文,文章末尾给出了这样一个 "curry": function curry(fn, ...args) { return (..._arg) => { return

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK