No, babel is correct because the arrow function assigned to var should theoretically have a name property equivalent to the name of this var to help in stack tracking and reflection. See this link for more details . A brief summary in case it is out of date:
The function name property is created at the time of declaration. The name property of the function expression is derived from the name binding:
var foo = function() {};
console.log(foo.name);
Arrow functions have the same behavior:
var foo = () => {};
console.log(foo.name);
, ES 2015/ES 6 babel function
var foo = function foo() {};
.