Changing the value of vuex in the beforRouterLeave guard does not take effect.

wants to send the collected data when switching routes, but does not generate

when changing the value of vuex.
beforeRouteLeave: (to, from, next) => {
  try {
    console.log(":"+new Date().getTime());
    this.$store.commit("GET_HTTPRESPONSETIME", new Date().getTime());
    this.closPages();
  } catch (error) {
    
  }finally{
    next();
  }
  

what"s wrong with writing like that?

Mar.04,2021

this does not need the arrow function

Menu