shyam-habarakada / js-virtual-list-view

A HTML component (modeled after UITableView) for rendering very large scrolling lists with high performance.
MIT License
22 stars 6 forks source link

ng-vlv (angularjs port) #1

Open shyam-habarakada opened 10 years ago

shyam-habarakada commented 10 years ago

Would be great to make an angular-js version of this same functionality. If anyone has thoughts, feedback or time to help, let me know.

gregorydickson commented 10 years ago

This is close: https://github.com/webux/ux-angularjs-datagrid

shyam-habarakada commented 10 years ago

@gregorydickson thanks for the pointer. yes it looks interesting. I agree with their decision to not (also) implement their own scroller. I will take a closer look.

gregorydickson commented 10 years ago

I am trying to build an image scroller that will scroll through a million images of around 30k. I am looking at https://github.com/airbnb/infinity and https://github.com/webux/ux-angularjs-datagrid and your component (oh, and doing it in a JavaFX rich client). Infinity.js seems the closest and I have it working with about 30,000 images but the data structures need to be rewritten and the scroll up and scroll down need to be different functions to optimize the lazy loading and unloading.

shyam-habarakada commented 10 years ago

js-vlv does not drop items off the top as you scroll down, so a million images could easily fill up all the memory. It is designed to be able to support that, and I just haven't had the time (nor need) to get to it. The problem it solves now is making the initial load much faster, and progressively loading if and when the user scrolls down. That covers a lot of common scenarios.

gregorydickson commented 10 years ago

Yeah, I have contemplated how to implement that. I might be able to fork and do the work but I might fork infinity.js. Not sure yet. At a million images even the array that holds the image ids gets really slow!!!

shyam-habarakada commented 10 years ago

Yup. As a design principle, we avoid solution that require having the entire world loaded. Even the facebook timeline (which behaves like the current js-vlv, and has a lot more developer effort put into it) will crash if you keep loading and expanding the history of posts.