I would like to ask the boss: VUE uses swiper carousel, pager and pictures are not Synchronize

vue uses Swiper for carousel, but exit the component and enter the component

Picture and pager do not Synchronize , and manually slide the picture , but the pager does not move ; similar to the following illustration.
clipboard.png


this.$nextTick(()=>{


clipboard.png


swiper in Vue you use Vue-awesome-swiper


the cache was written before. The data is on the activated hook. Every time the data is entered into the component, the Swper is requested. After the request is called back, Swper is called again, which causes
swiper
to be executed again in the cache. Now the hook placed in beforMount will not repeatedly call
every time it enters the component (considering that the broadcast graph and navigation will not change frequently, so you won't worry too much about not updating the data in time.)

clipboard.png

Menu