Skip to content

InfiniteLoader when scroll reverse do not respect minimumBatchSize #217

Closed

Description

@rodcorsi

If you test InfiniteLoader.example.js with some changes:

change line 26

    this.state = {
      loadedRowsCount: 0,
      loadedRowsMap: {},
      loadingRowsCount: 0,
      randomScrollToIndex: 500 //change here
    }

add a console.log line 122

  _loadMoreRows ({ startIndex, stopIndex }) {
    const { loadedRowsMap, loadingRowsCount } = this.state
    const increment = stopIndex - startIndex + 1
    console.log(startIndex+" => "+stopIndex+' increment:'+increment); //add this line
    for (var i = startIndex; i <= stopIndex; i++) {

when you scroll in reverse direction you can see the increment is always 1.

how can I do InfiniteLoader respect minimumBatchSize in both directions?

Activity

  1. bvaughn commented on May 8, 2016

    @bvaughn
    Owner

    Looks like a bug.

    My hands are pretty full with the version 7 update at the moment so I'm probably not going to get to this for a couple of days.

  2. bvaughn commented on May 14, 2016

    @bvaughn
    Owner

    @rodrigocorsi2: This has been fixed in version 7.0.5. Thanks for the bug report. :)

  3. rodcorsi commented on May 15, 2016

    @rodcorsi
    Author

    Thank you @bvaughn !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions