FIX: Ensure load-more considers current position (#8357)

The loadMore action was not called if user was already at the bottom
of the page.
This commit is contained in:
Dan Ungureanu 2019-11-18 15:09:47 +02:00 committed by GitHub
parent 352d43b101
commit 3650c64bca
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -21,6 +21,7 @@ export default Mixin.create(Scrolling, {
const eyeline = new Eyeline(this.eyelineSelector + ":last");
this.set("eyeline", eyeline);
eyeline.on("sawBottom", () => this.send("loadMore"));
eyeline.update(); // update once to consider current position
this.bindScrolling();
},