I run Boat Build Log , a free site where amateur boat builders keep a log of their build. A log is a list of dated entries, each with a paragraph or two and up to a couple dozen photos. Some builds take two years, so some logs get long.
A reader wrote in about a fourteen-entry log. He didn't like having to find and press "Later entries" at the foot of every page. He wanted the next page to just show up as he scrolled. Fair request, and it sounds like an afternoon of work. It mostly was. Then I shipped two bugs with it, and I'll walk through both.
Why the log is paged in the first place
The log page used to load every entry with all its media and comments in one response. That was fine at eleven entries. It wasn't fine for a Glen-L Squirt log, which was a two-year build with every photo coming down the wire as a single page. So the controller pages it, five entries at a time:
public const ENTRIES_PER_PAGE = 5 ;
Enter fullscreen mode
Exit fullscreen mode
Five is a reading unit, not a performance number.…