[combobox] Pagination with async requests
- Dominant language
- TypeScript
- Stars
- 10.9k
- Forks
- 543
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 101
Description
## Description
I started working on an example combining **Base UI Combobox** with **infinite async loading** using **TanStack Query (useInfiniteQuery)**.
This seems like a fairly common use case (large datasets, async search, infinite scroll), but I couldn’t find an official example or clear guidance in the Base UI documentation.
I have a public repository with a **partial implementation**, but due to time constraints I wasn’t able to finish it. I’m opening this issue mainly to:
- document a gap in examples/documentation
- share context and a starting point for this use case
- see if this aligns with the project goals or if there is a recommended pattern
## What’s missing
- No official example showing Combobox with **infinite async data**
- No guidance on:
- appending items while the list is open
- recommended patterns for async pagination
## What I tried
- Used `@tanstack/react-query` `useInfiniteQuery`
- Loaded more options on scroll
- Controlled the Combobox value while options are fetched incrementally
## Minimal / partial reproduction
The repository below contains a **work-in-progress example** demonstrating the idea, but it’s not finished yet.
**Repo:**
👉 https://github.com/farhantallei/base-ui-combobox-infinite-loading
## Closing
If this use case makes sense for Base UI, I’d be happy if someone from the team or the community could continue from this example, suggest the recommended approach, or point out if there’s a better pattern that should be documented.
Contributor guide
Assessment
This issue has not been assessed yet.