fix(runtime-core): avoid flicker when setRef on TransitionGroup children
fix: https://github.com/vuejs/core/issues/7754
Here's a Playground demonstrating this fix in action:
That's using the same code as the original bug report.
The fix seems to be working nicely.
Size Report
Bundles
| File | Size | Gzip | Brotli |
|---|---|---|---|
| runtime-dom.global.prod.js | 100 kB (+39 B) | 38 kB (+11 B) | 34.2 kB (+40 B) |
| vue.global.prod.js | 159 kB (+39 B) | 57.9 kB (+10 B) | 51.4 kB (-2 B) |
Usages
| Name | Size | Gzip | Brotli |
|---|---|---|---|
| createApp (CAPI only) | 47 kB (+39 B) | 18.3 kB (+11 B) | 16.7 kB (+16 B) |
| createApp | 55 kB (+39 B) | 21.3 kB (+10 B) | 19.4 kB (+25 B) |
| createSSRApp | 59 kB (+39 B) | 23 kB (+11 B) | 20.9 kB (-59 B) |
| defineCustomElement | 59.8 kB (+41 B) | 22.9 kB (+14 B) | 20.8 kB (+10 B) |
| overall | 68.7 kB (+39 B) | 26.4 kB (+12 B) | 24 kB (+34 B) |
@vue/compiler-core
pnpm add https://pkg.pr.new/@vue/compiler-core@7768
@vue/compiler-ssr
pnpm add https://pkg.pr.new/@vue/compiler-ssr@7768
@vue/compiler-sfc
pnpm add https://pkg.pr.new/@vue/compiler-sfc@7768
@vue/compiler-dom
pnpm add https://pkg.pr.new/@vue/compiler-dom@7768
@vue/reactivity
pnpm add https://pkg.pr.new/@vue/reactivity@7768
@vue/runtime-core
pnpm add https://pkg.pr.new/@vue/runtime-core@7768
@vue/runtime-dom
pnpm add https://pkg.pr.new/@vue/runtime-dom@7768
@vue/server-renderer
pnpm add https://pkg.pr.new/@vue/server-renderer@7768
@vue/shared
pnpm add https://pkg.pr.new/@vue/shared@7768
vue
pnpm add https://pkg.pr.new/vue@7768
@vue/compat
pnpm add https://pkg.pr.new/@vue/compat@7768
commit: 0fc9925
The underlying problem is that the following line has side effects. https://github.com/vuejs/core/blob/10a46f43c0d41f1e38616042d38b087c0ec1c829/packages/runtime-core/src/rendererTemplateRef.ts#L114
The underlying problem is that the following line has side effects.
https://github.com/vuejs/core/blob/10a46f43c0d41f1e38616042d38b087c0ec1c829/packages/runtime-core/src/rendererTemplateRef.ts#L114
OK. I understanded. thanks. https://github.com/vuejs/core/issues/8733