If you try to program in a functional style on JavaScript, you'll probably realize the conventional fn(obj,params...) form gets unreadable fast.
console.log(
join(
map(function(row){ return row.join(" "); },
format(
map(function(text){return align(text},
view),
20))),
"\n");
VS
view.map(function(text){return align(text)})
.format(20)
.map(function(row){return row.join(" ");})
.join("\n")
.log();
Problematically, the latter style could only be implemented extending the Object.prototype with new functions, which is globally regarded as evil. Yet, the readability is so superior that I'm prompted to just go ahead and do it anyway. Is there a better way to solve this problem?