ES6 Arrow Function All In One



ES6 Arrow Function All In One

this

const log = console.log;

const arrow_func = (args) => log(`args =`, args);
// OR
const arrow_func = args => log(`args =`, args);


const arrow_func = (arg1, arg2) => {
log(`args =`, args);
// return void 0;
}


应用场景


refs



​ ​





xgqfrms