-
Notifications
You must be signed in to change notification settings - Fork 141
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When JSX is used, v-slots cause child component does unnecessary rendering during parent component re-rendering #712
Comments
Hi folks, |
+1 same for me, same boat |
this is the last item I need updated to convert my project from vue2 to vue3, would love an ETA |
Is there an expected repair time? I think this has a great impact on performance |
Setting $stable to true in v-slots prevents updates for subcomponents,I'm looking at this issue:#525 |
v-slots={{ |
|
jsx 目前没有做这种编译处理, vue slot 有3种类型,stable、dynamic、forward,template 语法会在编译过程中根据上下文自动编译出插槽类型,从而在更新判断中做优化处理,而 jsx 没有做这种处理,所以会强制更新 |
stable 才会在更新过程中做优化,dynamic 会强制更新,forward 会根据运行时的行为决定 |
Any updates ? |
Vue version
3.4.21
Link to minimal reproduction
https://github.com/yuwu9145/vue-jsx-slot-demo
Steps to reproduce
What is expected?
Only parent App component's
onUpdated
hook should be triggered, child Test component should not be re-rendered as nothing is changed to trigger child Test render functionWhat is actually happening?
Both parent App and child Test components are re-rendered
System Info
Any additional comments?
No response
The text was updated successfully, but these errors were encountered: