js es6 语法: => 函数简化为箭头符号

=>es6语法中的 arrow function

(x) => x + 6

相当于

function(x){
    return x + 6;
};

 详见:js(=>) 箭头函数 详细解说 案例大全

猜你喜欢

转载自blog.csdn.net/weixin_41796631/article/details/83038139