Skip to content

Show older stream VODs on channel pages - #84

Merged
t3dotgg merged 2 commits into
mainfrom
t3code/paginate-vod-list
Sep 25, 2026
Merged

t3dotgg merged 2 commits into
mainfrom
t3code/paginate-vod-list

Conversation

@t3dotgg

@t3dotgg t3dotgg commented Sep 25, 2026 •

Copy link
Copy Markdown
Member

Channel pages showed only the first page of Twitch videos (20 items). Older streams were missing. The list also mixed past streams with highlights and uploads.

The list now gets only past broadcasts (type=archive), 100 per page. Twitch keeps past broadcasts for 60 days at most, so almost every channel fits on one page. When Twitch has more, the page shows an "Older VODs" link. Later pages show a "Latest VODs" link.

Other changes:

  • A later page with no VODs shows "No older VODs." It does not show the "No VODs found for this channel" state. Twitch can return an empty page near the end of the list.
  • A page change moves the scroll back to the top and shows the loading state. Before, Next kept the same scroll container, so you stayed at the bottom of the old list with no feedback.
  • A failed live-stream check does not hide the list. The error goes to the server log. The live VOD can then show in the list.
  • An unknown user now gets the empty state, not an error page.

Tests: pnpm test (31 passed), pnpm typecheck, pnpm lint, and pnpm build pass. I checked the scroll and loading fix in headless Chromium, on a Next 16.3.6 production build of a copy of this page layout. I did not test with the live Twitch API. The page size, empty page, and cursor behavior are checked against the Twitch docs and by code reading only.

The open VOD UI PR #81 also edits vods.tsx. It must keep this pagination when it is rebased.

Created with GPT-6 Astra in Codex. Takeover fixes by Claude Opus 5.5 in Claude Code.

🤖 Generated with Claude Code

@vercel

vercel Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
markerthing Ready Ready Preview Sep 25, 2026 4:12am UTC

Request Review

@coderabbitai

coderabbitai Bot commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 55 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 2 included reviews currently available.

Only developers with an assigned seat can use this organization's usage-based review budget, and seats here are assigned manually. Ask an admin to assign a seat, or change the review continuation mode in Billing.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: 627e8341-9371-4fd4-8d3a-994c90938576

📥 Commits

Reviewing files that changed from the base of the PR and between 688e1e4 and ad119bd.

📒 Files selected for processing (2)
  • src/app/[slug]/page.tsx
  • src/app/_components/vods.tsx

Comment @coderabbitai help to get the list of available commands.

@greptile-apps

greptile-apps Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

RetriggerConfidence Score: 5/5

[Medium risk] Adds pagination to the VOD listing on channel pages.

The PR appears safe to merge; no outstanding findings or new actionable issues remain.

Reviews (2) · Last reviewed commit: "Load 100 VODs per page and fix empty lat..."

Comment thread src/app/_components/vods.tsx
Comment thread src/app/_components/vods.tsx
Comment thread src/app/_components/vods.tsx
…hange

Twitch keeps past broadcasts for 60 days at most, so the max page size of
100 fits almost every channel on one page. An empty later page now says
"No older VODs" instead of the "no VODs for this channel" empty state.
Changing pages now resets the scroll and shows the loading state, because
Next reuses the page div when only the search params change. A failed
live-stream check is now logged.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@t3dotgg

t3dotgg commented Sep 25, 2026

Copy link
Copy Markdown
Member Author

Note

🤖 Claude Opus 5.5 responding on behalf of Theo

@greptileai review. ad119bd changes the page size to 100, adds the "No older VODs" state, resets scroll on page change, and logs failed live checks.

@t3dotgg
t3dotgg merged commit 7d4584c into main Sep 25, 2026
6 checks passed

This branch was successfully deployed

1 active deployment
Preview — ad119bdb Deployed Sep 25, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant