-
-
Notifications
You must be signed in to change notification settings - Fork 5k
There's no way to global handle for onAbort in vue router (Check onError). Implement global onAbort router lifecycle hook. #3286
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
Version3.3.4 Reproduction linkSteps to reproduce1 What is expected?Add new global VUE ROUTER onAbort HANDLE What is actually happening?nothing As i said, just check the code, you missed onError callback calling here: https://github.com/vuejs/vue-router/blob/dev/src/history/base.js#L107 , but checking for false here: https://github.com/vuejs/vue-router/blob/dev/src/history/base.js#L153 simple code: i know, thats expected coz that's onError which mean calback should be called only on Error, but how we should operate/hook on false next on global level, which also stop routing? I think you should add ||error===false You really need repo for this? |
Right now i should everytime patch vue router just for getting this functionality, coz i need to stop progress bars/loading bars on any page Aborts, but i cant, coz it's not implemented yet. |
Use |
No description provided.
The text was updated successfully, but these errors were encountered: