tree does not render when nodes fetched within a timeout
When I put nodes creation inside a timeout, tree does not render. Created a plunkr that you can see the problem https://plnkr.co/edit/c0LTf5?p=info
Essentially with timeout I am simulating nodes fetching from http webservice call.
The same issue - happens after AppPool recycled. Also error is displayed in the console: "[mobx.array] Attempt to read an array index (0) that is out of bounds (0). Please check length first. Out of bound indices will not be tracked by MobX"
After refresh with disabled cache tree appears but error is still diplaying
Same issue here - works when reverting @outerbound's plunk to v2.8.2 (before virtual scolling) https://plnkr.co/edit/2DbXj9R3km6MmIp44Ajh
Fixed in 3.2.1 - please upgrade
Thanks, that fixed it!
Sorry I missed virtual scrolling was disabled by default - not working in v3.2.3, please see https://plnkr.co/edit/nROjem69yZTW8hVcemp8?p=preview
TreeVirtualScroll.getViewportNodes() expects viewportHeight to be truthy before it allows setting nodes.
A workaround shown in the plunk below, is to apply a height to <viewport> using component style:
:host >>> tree-viewport { height: 600px; }
https://plnkr.co/edit/z2RcVRj0QUJIWVEGhTYy?p=preview
Hi, I'll look into it this weekend
--
- Adam Klein http://il.linkedin.com/in/adamklein500
- CTO @ 500Tech.com http://500tech.com/
- AngularJS, ReactJS, NodeJS
- Development, consulting, training and public speaking
- (+972) 52 747 5633
On Tue, Mar 14, 2017 at 4:43 PM, JanPrinsloo [email protected] wrote:
TreeVirtualScroll.getViewportNodes() expects viewportHeight to be truthy before it allows setting nodes. A workaround shown in the plunk below, is to apply a height to
using component style: :host >>> tree-viewport { height: 600px; }
https://plnkr.co/edit/z2RcVRj0QUJIWVEGhTYy?p=preview
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/500tech/angular-tree-component/issues/208#issuecomment-286442761, or mute the thread https://github.com/notifications/unsubscribe-auth/AA2SShsWrVRGNKTjVqDOjmiWrX89Dq_fks5rlqeNgaJpZM4MUV0- .
I use v3.7.3 have the same issue. I use @JanPrinsloo's workaround, it's work. @adamkleingit Is the issue fixed?