This site has two lists that grow on their own:
- The changelog
/changelog(in Chinese), generated automatically from gitfeatcommits. November alone had 161 items, 116 of them in the last week. - The series list in posts: the "Running a self-hosted site" series reached part 13, and every post in it opens with all 13 titles.
Both are the classic case of "looks great when you build it, gets out of hand a while later". I measured with Playwright at 390px wide:
| Page | Page height on a phone | Roughly how many screens (844px) |
|---|---|---|
/changelog | 17,559px | 21 |
| Start of a series post | the body only starts in the middle of the second screen | 1.5 |
The principle: readers come for "the latest" and "this post"
A changelog reader wants to know "what changed recently", not to read every line since June; a post reader came for this post, and the series list is further reading, not the opening. So both use the same trick: show only the small part that is needed most, fold everything else into one line, and open it on request.
None of this needs JavaScript. HTML already has <details> and <summary>, supported by keyboards and screen readers, and a Server Component can output it directly.
Changelog: group by week, open only the latest week's first 10 items
Month headings stay the same. Under each month, items are grouped by week (starting Monday), one <details> per week:
Only the first week of the whole list is open. But that alone is not enough: the latest week has 116 items by itself, and opening it is still a long wall. So the open week lists only 10 items first, and the rest are folded into a second level, "the other 106 items this week ▸". Nested <details> need Tailwind's named groups (group/more, group-open/more:), or the inner arrow changes along with the outer one.
Also, commit messages are written for myself, and often end with a parenthetical holding details like a scheduled task's name or a log path. For visitors that is noise, but deleting it would be a waste, so I split it in two layers: the trailing full-width parenthetical is split off and shown in smaller, faded text under the main sentence. The matching works backwards from the end, because parentheses can nest; parentheses in the middle of a sentence are left alone.
After the change the page on a phone went from 17,559px to 2,431px.
Series list: looks like the table of contents
Post pages already have a collapsed "Contents" section, so the series list now looks the same:
Two lines side by side, with the same left border, so readers see at a glance that they are the same kind of thing. The series list used to be a filled box, full width on desktop while the body text was only half as wide, so the right edge did not line up and it looked heavy. Folding it into one line solved that too.
On the side: the "now" page no longer repeats the changelog
The "recently working on" part of /now was just the first 5 changelog entries, duplicating /changelog, in raw commit text. nownownow.com's original idea is to write about a person's current situation, so I changed it: the hand-written "learning, busy with" goes at the top, then the 3 most recent posts, and the site's own updates are down to a single line linking to the changelog.
Takeaway
For a list that grows by itself, ask while building it: "what does it look like at 10 times the size?" This fix used no new package and no new client component, just an element HTML already had.