Arrow function syntax vs function definition


#1

Are there any differences between creating a function using arrow function syntax and the traditional function definition syntax? I’ll provide an example:

const myFunction = () =>{
return (‘Output’);
}

function (myFunction){
return (‘Output’);
}

I guess both would return the same, but I wander if there are any differences I am not aware of.
Thanks in advance.


#2

Please see here:

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions

it explains the new arrow syntax (shorter, binding of this keyword) and so on