Data is requested in vue, but cannot be printed.


Mar.18,2021

ajax request is asynchronous. After your data request is successful, console.log () has been executed. You need to mention this sentence in if (res.data.code = 100)


do you declare _ that = this?? If so, please console.log (_ that.applyDataArr);


isn't $http asynchronous? If you execute console first, you won't be able to print it out.

Menu