Comments (2)
没有失效啊,这边我限制了渲染 30 个节点,实际 block area 子节点个数 32 个,减去头尾两个撑高度的,刚好是 30 个。
检查一下你的树组件外层的容器是不是没有给一个高度,虚拟列表计算是需要拿到 scroll area 这个 div 的 clientHeight 的。
https://codesandbox.io/p/sandbox/vue-tree-render-node-amount-yyt2v5
from vue-tree.
没有失效啊,这边我限制了渲染 30 个节点,实际 block area 子节点个数 32 个,减去头尾两个撑高度的,刚好是 30 个。 检查一下你的树组件外层的容器是不是没有给一个高度,虚拟列表计算是需要拿到 scroll area 这个 div 的 clientHeight 的。
https://codesandbox.io/p/sandbox/vue-tree-render-node-amount-yyt2v5
问题解决,非常感谢。我直接把 vue-tree 放到最顶层容器里测试,没有设置高度,导致会渲染所有节点,设置高度后就生效了。
from vue-tree.
Related Issues (20)
- vue-cli新创建的项目咋集成不进来呢 HOT 9
- 鼠标右键时间,获取不到事件对象 HOT 1
- 大佬请教一下,修改其中一个数据的状态,怎么触发试图更新 HOT 1
- 优化建议
- 组件没有销毁方法,导致内存一直下不去 HOT 7
- vue 2 项目使用的时候编译报错 HOT 4
- 加载十万条数据的时候,勾选根节点会卡住,内存和cpu都爆满,有解决方案吗 HOT 1
- 我希望勾选的时候父勾选,子节点都勾选,子节点取消勾选,父不变 HOT 1
- 我有3000个节点,全部取消勾选瞬间就取消了,但是全部勾选要等一下才能勾上,为什么?? HOT 1
- 这个为啥没报错
- TreeDrop单选时报错 HOT 1
- 懒加载的箭头问题 HOT 1
- 下拉树数据量大会存在内存泄漏 HOT 1
- 怎么只更新某一个节点的样式? HOT 2
- 右键菜单事件没有 event 参数 HOT 1
- 右键菜单事件参数没有鼠标事件 event HOT 1
- check和uncheck事件触发时,会先触发check事件 HOT 1
- 使用 TS 的时候提示找不到定义 HOT 10
- 节点当前行高亮样式建议 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vue-tree.