how can I issue an alert to the user when he wants to leave the form with input filled without saving?
I have already tried to implement something inside beforeDestroy, but I can not abort the output
Can I abort the screen output inside the:
router.beforeEach((to, from, next) => {
if(!store.getters.getStatusEdit){
next(false);
}
})
But it did not work, because the vuex that runs inside beforeDestroy runs after the route.
Anyone have any suggestions?