mirror of
https://github.com/cloudflare/vinext.git
synced 2026-05-09 08:25:34 +02:00
[GH-ISSUE #375] feat: support parent parameter in generateMetadata() #84
Labels
No labels
enhancement
enhancement
good first issue
help wanted
nextjs-tracking
nextjs-tracking
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/vinext#84
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @james-elicx on GitHub (Mar 9, 2026).
Original GitHub issue: https://github.com/cloudflare/vinext/issues/375
Summary
Next.js's
generateMetadata()accepts a secondparentparameter of typePromise<ResolvedMetadata>, which resolves to the accumulated metadata from ancestor segments. This allows patterns like:Next.js uses an eager-execution-with-serial-resolution approach: all
generateMetadata()calls are kicked off concurrently, but theparentpromise for each segment resolves serially from root to leaf.Current behavior
vinext's
resolveModuleMetadata()does not pass aparentargument. Apps usingawait parentingenerateMetadata()receiveundefinedand will likely throw or produce incorrect metadata.Expected behavior
generateMetadata()should receive aparentpromise that resolves to the merged metadata from all ancestor segments, matching Next.js behavior.References