Vue调用钩子函数mounted时报错:
[Vue warn]: Error in mounted hook: "TypeError: handler.call is not a function"
错误代码:
// 页面显示之前调用
mounted: {
this.device_view();
},
正确代码:
// 页面显示之前调用
mounted:function () {
this.device_view();
},
[Vue warn]: Error in mounted hook: "TypeError: handler.call is not a function"
// 页面显示之前调用
mounted: {
this.device_view();
},
// 页面显示之前调用
mounted:function () {
this.device_view();
},