Skip to content

Conversation

@rajanarahul93
Copy link

Summary

This adds a new /changelog page to the documentation. It fetches published releases from GitHub, parses their release notes, and presents them in a readable, category-grouped format (Features, Bug fixes, Documentation, Other changes). The page reuses the existing PullRequestLine component so each entry includes PR metadata, author attribution, and status indicators.

This gives the project a clear, easy-to-scan changelog directly in the docs without relying on GitHub Releases.

Root cause

The documentation didn’t previously have a centralized changelog. Users had to browse GitHub Releases manually, which doesn’t offer the same readability, grouping, or attribution available in the docs experience.

Changes

  • Added packages/docs/src/app/changelog/page.tsx.
  • Implemented GitHub API release fetching (excluding drafts and prereleases).
  • Parsed release bodies into semantic categories based on markdown headings.
  • Extracted PR numbers and displayed attribution using PullRequestLine.
  • Enabled ISR via export const revalidate = 3600 so the changelog stays current.

Screenshots

Click to view local rendering

Note: Vercel preview builds for PRs originating from forks do not receive GITHUB_TOKEN.
PR metadata (avatars, labels, and merge status) will not load in the preview.
The screenshot below shows the correct rendering when the token is available locally.

image

Testing

  • Verified the changelog loads at /changelog.
  • Confirmed releases are fetched in descending order.
  • Ensured category grouping is correct for Features, Bug fixes, Documentation, and Other changes.
  • Verified PR attribution rendering using PullRequestLine.
  • Confirmed the empty state displays when the GitHub API cannot be reached.

Risk & Rollback

Risk: Low, the feature is isolated and does not affect existing pages.
Rollback: Simply removing packages/docs/src/app/changelog/page.tsx fully reverts the change.

Related

Closes #1251

@vercel
Copy link

vercel bot commented Dec 6, 2025

@rajanarahul93 is attempting to deploy a commit to the 47ng Team on Vercel.

A member of the Team first needs to authorize it.

@vercel
Copy link

vercel bot commented Dec 6, 2025

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

Project Deployment Review Updated (UTC)
nuqs Error Error Dec 24, 2025 6:20am

@franky47 franky47 changed the title feat(docs): add changelog page doc: add changelog page Dec 6, 2025
@franky47 franky47 added the documentation Improvements or additions to documentation label Dec 6, 2025
@franky47 franky47 added this to the 🪵 Backlog milestone Dec 6, 2025
Copy link
Member

@franky47 franky47 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

There are a few things to change, another thing that I couldn't comment on is that the PullRequestLine component currently doesn't render related issues the same way the changelog does, that could be a good improvement to add.

title: 'Changelog'
}

export const revalidate = 3600
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Make the whole page static, and only invalidated (ISR) via tags when we publish a new release.


type ReleaseNoteItem = {
text: string
prNumber?: number
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Each release note item should have a number link (either PR or issue, GitHub doesn't really make a difference), so this type could be made to be required (and the parsing code adapted accordingly).

return []
}

const data = (await response.json()) as GithubRelease[]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Use zod to parse the response and infer the type from its schema.

// Headings like "### Features", "### Bug fixes", etc.
const headingMatch = /^#{2,3}\s+(.+)$/.exec(line)
if (headingMatch) {
currentCategory = classifyHeading(headingMatch[1])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: This will classify unrelated headings as "other changes", like the Thanks section.

return (
<main className="mx-auto max-w-4xl px-4 py-10 space-y-10">
<header className="space-y-2">
<h1 className="text-3xl font-semibold tracking-tight">Changelog</h1>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Use the typography from Fumadocs (see the blog & registry pages for examples).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: This page should share the same layout as other pages, to include the top nav, otherwise once in the changelog there is no way back.

className="space-y-1"
>
<p className="text-sm text-gray-800 dark:text-gray-100">
{item.text}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: The text is not necessary as it's rendered in the PullRequestLine component.

This causes it to be rendered twice:

Image

@rajanarahul93
Copy link
Author

rajanarahul93 commented Dec 7, 2025

Thanks! Implemented this. Let me know if you'd like any follow-ups.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Changelog page in the docs

2 participants