Nov 25, 2024
Depends on what you want to accomplish, I suppose. Result type could be a struct like the following.
struct PaginatedResults<T> {
let results: [T]
let more: (() -> Void)?
}
With more being a closure one could call to fetch more data. If no closure, no more data.