Join the Webstudio community

Updated 3 months ago

database website with 100k+ airtable records

At a glance
@Oleg Isonen Hi. I have a quote for creating database website with 100k+ airtable records. Need filter, sort and search functional and lazy loading of items. Is Webstudio a good solution to make such thing?
O
b
I
34 comments
When you say lazy loading, do you have specific ux pattern in mind?

With pagination there is no problem, even though I would recommend baserow instead of airtable
Load more or infinite scroll are much harder, pagination or just "Next page", "Previeous page" buttons is easy, so you never load more than x items using your query
For this pattern we have videos on YT
I thought more about load more button or lazy loading on scroll. But pagination might work as well.
What about filtering and search, are they easy to implement?
Thank you for baserow recommendation, I will look into that
load more and scrolling requires complex update patterns, as you need to insert more at the end without rerendering everything, then in addition to that at some point you will have loaded too much in the DOM, you will need virtualized lists ... don't go into that rabbit hole
filtering and search are easy and we have videos for it
its not 100k records, but this doesn't matter, because we never load all of them
Awesome, thank you for help!
Hey @Oleg Isonen
I'm finally working on this project and have couple questions.
1) I am using radix select component for filters. How can I keep item selected after resubmitting the form? You have example for checkboxes but I cannot get how to do it for select.
2) I need to skip a step with hitting 'filter' button for users. Is the best way to achieve this - write a script that clicks button automatically after user select something?
3) How to get pagination work? Do you have any tutorial on this? Currently my next button only scrolls to top of the page but doesnt paginate at all
  1. value on the select root same as value on the item
Attachments
image.png
image.png
  1. we do on yt, at least for some systems, not sure if airtable was one of them
Yeah I set it up like this. It works fine inside builder but on published site it resets select root for some reason 🥲
did you bind the value to url query?
it is supposed to reset after submission and won't be set to the value you submitted unless you use url query, that's how we showed it for checkboxes as well
I made it like this for select root and seems like it worked. Thank you!
Attachment
image.png
I got pagination to work as well. Is there any change to prevent scrolling on top of the page after using pagination? I see this behavior on marketplace template as well.
Also can I somehow prevent clearing filters after using pagination? For example - user made a query and it returned 100 results, while only 10 can be shown. Once I paginate - filters reset
scrolling thing shouldn't happen, sounds like a bug we fixed at some point in the past, @Ivan Starkov right?

as for page settings you need to make sure page is in the url query and use that value for the next page, effectively next page should always know what the previous page is, it should be like that in the marketplace examples
https://www.loom.com/share/21f25c991bb84c13a401b330e8acc4bf?sid=e77b3657-89bf-4fb7-bd24-73230129d953

Here is an example how it works with marketplace wordpress template. As you can see, scrolling is still happening
https://github.com/webstudio-is/webstudio/pull/4267

works only if navigation is on the same page
preventScrollReset={action === undefined || action === ""}
Uhh regarding scroling I thought you are talking about form submission
but you are talking about clicking on a pagination link
links indeed would scroll up
not sure this is a bug
Try to add preventScrollReset to the Link attributes
indeed we have that property
Attachment
image.png
value "true" or bind to true value, not sure what will work
or false Im not sure why it does not reset scroll
May be some js is used
Yes, this worked perfectly! Thank you so much
@Oleg Isonen Hello Oleg
I have one more question I cannot get around. Why I cannot order by id or order fields from baserow? I can sort by any field except order and id. It returns error that in cannot get 'order' field. But is see that fields in results if I inspect
Attachment
image.png
Add a reply
Sign up and join the conversation on Discord