Is there a way to get previous page of products with JavaScript Buy SDK similar to "fetchNextPage"?

fozweb
New Member
3 0 0

I am using the Buy SDK, and trying to figure out pagination.  The SDK provides a "fetchNextPage" function, but does a "fetchPreviousPage" function not exist?  Is there another specific way I should be approaching this?

My working code:

    client.fetchNextPage(collection)
        .then((nextPageOfProducts=> {
            console.log(nextPageOfProducts)
        })
 
Now just need to figure out how to go backwards

 

Replies 0 (0)