-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[vue] 怎么捕获组件vue的错误信息? #327
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
errorCaptured |
errorHandler |
Vue.config.errorHandler = function (err, vm, info) {} 捕获所有组件 |
全局: errorhandler |
全局错误处理可以通过Vue的config.errorHandler方法来注册全局错误处理器,用于捕获整个应用程序范围内的未捕获的错误。
组件错误边界Vue 2.x并没有内置的组件级错误处理机制,但你可以使用Vue的errorCaptured钩子函数来捕获并处理单个组件内的错误。
|
[vue] 怎么捕获组件vue的错误信息?
The text was updated successfully, but these errors were encountered: