Help with pagination
I tried implementing pagination, but I keep getting this error.
This is how I am setting it up for pagination:
I believe the problem is with setting up the external part as such:
But I am not sure where to put my object to make this work — if this is even the correct way to utilize pagination.
Where am I going wrong?
Best Answer
-
I found a different route. I am using Draftbit as the frontend, so I created a function to set all the created_at variables into relative time stamps.
Answers
-
After messing with this more, I noticed that the error only appears due to the for loop I have:
How can I get this to work while still having the for loop, as this helps me to display timestamps
-
The error
please use a numerically indexed array
means that the 'array' we're passing into the loop might not actually be readable as an array itself.
As you run and debug, in the debugger, when you expand all the variables, what doesclub_news
show us?
Is this a list of objects as we'd expect, or something else? Thanks! -
club_news is an object with paging metadata. Iterate over club_news.items to crack this immediate issue.
-
React Native FTW!
Categories
- All Categories
- 53 ? Announcements
- 47 ? Releases
- 37 ? Welcome
- 983 ? Help! I'm a Noob
- 125 ? No-Code Front-Ends
- 633 ? Working with APIs
- 439 ? Transforming data
- 126 ? Connect Xano to ...
- 50 ?? Find an Expert
- 348 ❓Other questions
- 35 ? Security
- 22 ✂️ Snippets
- 19 ? Showcase
- 7 ?️ Xano Chatter
- 62 ? Video Tutorials
- 171 ? Request a feature
- 229 ? Report a Bug
- 19 ? Templates & Extensions
- 7 ? Feedback