Will vuex store data too frequently so that the value will not change?

scene

I have a player component that passes events to another sibling page in the event of timeupdate , and I use vuex to pass data between them.

Code

// player.vue
<template>
  <div class="player">
  ...
    <audio  @timeupdate="updateTime" :src="`xxx.mp3`"></audio>
  </div>
</template>

import {mapMutations} from "vuex";
export default {
  name: "player",
  methods:{
    updateTime(e) {      
    //
    let currentTime=e.target.currentTime;
    this.setCurrentTime(currentTime)
    },
    ...mapMutations({
      setCurrentTime: "SET_CURRENT_TIME"      
    })
  }

}
// 
import {mapGetters} from "vuex";
<template>
  {{currentTime}}
</template>

export default{
  name:"xxx",
  computed:{
   ...mapGetters(["currentTime"])
  }

}
The currentTime on the

page has always been the initial value 0 in state . Is it cool if the setvalue is too fast?

Thanks in advance.

Apr.30,2021

No, it's usually a mistake.


have you found anything wrong, because I occasionally cause this problem when I use vuex to store the data returned by websocket? Lost data

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1eb3f08-248d.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1eb3f08-248d.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?