-
Notifications
You must be signed in to change notification settings - Fork 2
Add Infinite scroll #18
base: master
Are you sure you want to change the base?
Conversation
@kbariotis wow, this looks really awesome 😃 Did you look into if it would be possible to load more results automatically as the user scrolls towards the end of the list? - instead of having to click a button (like twitter) |
Hello @watson! Thx! Aw I completely missed that! Well, I guess It would be possible. The only thing that concerns me is that the initial request must fetch so many items that can fill the user's viewport, so she can scroll down and fetch more. We can fetch the user's device on runtime and decide how many to fetch, and then fetch a fixed amount of items for each additional request. Sounds good? What do you think? |
I see your point, but let's just keep it pragmatic. There's a header of 350 pixels above the first result and each result is 44 pixels. So how about just fetching 50 results each time? That would allow for a resolution of 2550 pixels vertically not counting the browser chrome. A newer 27" monitor in portrait orientation have 2560 pixels vertically, so that should be ok. We could just keep the button but click it programatically when ever the user approaches the end of the list. That way if for some reason the automatic click doesn't fire, the user can just click it him self 😃 |
Absolutely! Lets try it. |
Ready @watson! I kinda duplicate the |
LGTM 😃 - Any input @vanjacosic? |
Any update on this @watson @vanjacosic ? |
This is my take to resolve #17.
Thank you :)