看vuex案例时,头次看到这么个写法,很是不解exportfunctioncreateMessage({text,thread},cb){consttimestamp=Date.now()constid='m_'+timestampconstmessage={id,text,timestamp,threadID:thread.id,threadName:thread.name,authorName:'Evan'}setTimeout(function(){cb(message)},LATENCY)}想请教下这边的cb用法及含义
人到中年有点甜
胡子哥哥
相关分类