-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
fix(blog): apply proper route to metadata call #8224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
💡 Enable Vercel Agent with $100 free credit for automated AI reviews |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes an issue where blog pages were using the incorrect metadata generation route. The change ensures that blog-specific metadata is properly generated by creating a dedicated generateBlogMetadata function that includes the blog prefix in the route path.
- Creates a new
generateBlogMetadatafunction that properly constructs blog metadata routes - Updates blog pages to use the new blog-specific metadata generation function
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| apps/site/next.dynamic.page.mjs | Adds new generateBlogMetadata function with proper blog route handling |
| apps/site/app/[locale]/blog/[...path]/page.tsx | Updates blog pages to use the new blog-specific metadata function |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8224 +/- ##
==========================================
+ Coverage 76.43% 76.44% +0.01%
==========================================
Files 115 115
Lines 9643 9643
Branches 316 317 +1
==========================================
+ Hits 7371 7372 +1
+ Misses 2271 2270 -1
Partials 1 1 ☔ View full report in Codecov by Sentry. |
ovflowd
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SGTM!
Description
The base generateMetadata function is not taking
/bloginto account.I don't quite understand this next convention and the params type and how it relates to our code -
/blogis not coming in on the initial entrypoint.This is also affecting the download archive logic. Perhaps we can code-golf a solution that doesn't require duplication.
Live at https://nodejs.org/en/download/archive/v24.10.0
Validation
View title at https://nodejs-org-git-8223-blog-title-openjs.vercel.app/en/blog/release/v24.10.0
Related Issues
Check List
pnpm formatto ensure the code follows the style guide.pnpm testto check if all tests are passing.pnpm buildto check if the website builds without errors.