vue-worker icon indicating copy to clipboard operation
vue-worker copied to clipboard

how to use vue-worker in Axios

Open yzw7489757 opened this issue 5 years ago • 1 comments

for example,request callback

getCoreIndicatorList(params).then(({ data }) => {
       this.$worker.run((context,source)=>{
          context.coreIndicator= source.todayTotalAmount | 0
      },[this,data]).
       .then(() => // do something})
       .catch(console.error)

Failed to execute 'postMessage' on 'Worker': function () { [native code] } could not be cloned.

yzw7489757 avatar Jun 03 '19 03:06 yzw7489757

Your code sample has a typo: this,data should be this.data.

chris-canipe avatar Apr 17 '20 20:04 chris-canipe