I guess backend can send additional information eg. last_page:true
And accordingly frontend can stop asking for more data. This code should be easy to extend.
This will come in handy. Thanks for sharing, Jantu!
Very Insightful article! Loved it โค
Akshay Bhaskare
I have implement the above code for infinite scrolling in my project and its working fine, but there is a problem when all the data is loaded in the page it is still making API server call for more data when i scroll down, scrolling or loder should stop at the bottom when all the data is loaded, so please help me how i can achieve that