-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[vue] 使用vue渲染大量数据时应该怎么优化?说下你的思路! #444
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
Comments
1.如果需要响应式,考虑使用虚表(只渲染要显示的数据); |
感觉 freeze 是有点多余了,其实本质就是不想要 vue 去观测吧。 |
大佬你来啦 |
做分页,没有必要渲染这么多数据,一个屏幕都看不完。 |
可以试下可视化渲染 |
虚拟列表:vue-virtual-scroll-list,vue-virtual-scroller…… |
如果你有一个巨大的数组或对象,不需要被观测,他的数据是纯展示的,你又需要写在data里,那就用 Object.freeze去冻结他,Vue在内部会跳过对它的观测 |
[vue] 使用vue渲染大量数据时应该怎么优化?说下你的思路!
The text was updated successfully, but these errors were encountered: