htmx Infinite Scroll | Alchemists

06-Mar-2026 355
Pagination is always a feature you have to tackle in web application development in one form or another. A common approach is to use a gem, like Pagy, to provide the following capabilities: Load records in batches (a.k.a. pages). Previous and next links. Numbered links to specific pages. Bookmarkable links complete with browser history. Definitely useful to decrease server load since you’re only loading a small subset of records per request. The problem with this approach is: Most people bail after reading through the first couple of pages and not finding what they want. Includes a lot visual information, design-wise, that not only consumes real-estate within your UI but is seldom utilized.

Free eBook download

Download all our eBooks for free from Gumroad!
Prepare for your next tech interview with our comprehensive collection of programming interview guides. Covering JavaScript, Ruby on Rails, React, and Python, these books offer thousands of essential questions and answers across multiple languages. Download the complete collection for free from our Gumroad page. Free Ultimate Job Interview Preparation eBook collection