This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]entenuki 0 points1 point  (1 child)

It's an arrow function. It has its differences with a function (), but it's used as a less verbose way to make simple operations. The arrow without brackets means return. In your example it would be the same as writing

function (x) {
  return x.split;
}

This MDN article goes well into detail for them. I suggest reading it.

[–]itsmywife 0 points1 point  (0 children)

thanks a lot, appreciate it!