Subscribe on changes!

defineAsyncComponent not cache same component when rerun

avatar
Oct 14th 2021

Version

3.2.20

Reproduction link

sfc.vuejs.org/

Steps to reproduce

  1. open Devtool
  2. click button

What is expected?

Comp should not be re-rendered

What is actually happening?

Comp will be remounted

avatar
Oct 14th 2021
  1. You change the content of key
  2. that makes the computed update
  3. The computed returns a new component
  4. That new component is mounted after the old one has been unmounted.

This is expected behaviour.