Skip to content
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

Should isItemLoaded return true for in-progress items? #765

Open
WofWca opened this issue Jun 10, 2024 · 0 comments
Open

Should isItemLoaded return true for in-progress items? #765

WofWca opened this issue Jun 10, 2024 · 0 comments

Comments

@WofWca
Copy link

WofWca commented Jun 10, 2024

i.e. for items that are currently being loaded (while the loadMoreItems promise is pending).

The docs seem to be written in a way that suggests that no,
https://github.com/bvaughn/react-window-infinite-loader/blob/56720a7b813924a4c3dd10583d26744c96901c30/README.md?plain=1#L81-L98

but the code doesn't seem to remember whether it has started to load particular items
https://github.com/bvaughn/react-window-infinite-loader/blob/56720a7b813924a4c3dd10583d26744c96901c30/src/InfiniteLoader.js#L107-L178

I did some testing, and for me it didn't look like items were loaded twice, though perhaps it's just because the promise resolves too fast for me. But for slower promises, we might request items twice I suppose, which is a little inefficient?

Related: #630

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant