Skip to content
This repository has been archived by the owner on Jul 4, 2021. It is now read-only.

Not able to fetch next page(getNextPage) if adding model to fullcollection #312

Open
ankurgupta opened this issue Feb 16, 2016 · 2 comments

Comments

@ankurgupta
Copy link

If i am adding a new model to this.myCollection.fullCollection.add(model), its getting added to next page(with total element in the page =1). But when i am trying to fetch my next page, i am getting error (no links found for this page). I don't understand the reason. Any suggested solution please?

@wyuenho
Copy link
Member

wyuenho commented Mar 15, 2016

Infinite mode is best used read-only. If you create a record during pagination under infinite mode, you have to go into the links hash to update the offset. If you've created a new page, you'll have to manually adjust the links hash. Suggestions for improvement welcome.

@emileber
Copy link

If you're after infinite scroll or something akin to this, without a need for paging, I made an infinite collection inspired by the API of this lib.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants