DEV Community

Discussion on: Fuck you, Internet Explorer 💖

Collapse
 
thejaredwilcurt profile image
The Jared Wilcurt
x=>y=>(z,a)=>{
  return (z) => {
    return (a) => b
  }
}
Enter fullscreen mode Exit fullscreen mode

stinky stinky stinky. If you convert it back to normal functions and it looks like an abomination, you're coding wrong.

function (x) {
  return function (y) {
    return function (z,a) {
      return function (z) {
        return function (a) {
          return b;
        };
      };
    };
  };
}
Enter fullscreen mode Exit fullscreen mode

It's the same for nested ternaries. It is the result of someone being clever and trying to put everything into one line. Being clever is the fastest way to writing bad code.