fix: fixed statically indexed path for turbopack#8633
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
👋 Codeowner Review RequestThe following codeowners have been identified for the changed files: Team reviewers: @nodejs/web-infra Please review the changes when you have a chance. Thank you! 🙏 |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8633 +/- ##
==========================================
- Coverage 75.09% 75.05% -0.05%
==========================================
Files 104 104
Lines 9088 9088
Branches 314 315 +1
==========================================
- Hits 6825 6821 -4
- Misses 2261 2265 +4
Partials 2 2 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Pull request overview
Hot-fix to address Next.js/Turbopack warnings about overly broad static path analysis when resolving localized Markdown file paths for the site’s dynamic router.
Changes:
- Pre-compute the base
pages/directory path once ingetDynamicRouter. - Replace
path.join(process.cwd(), 'pages', locale, filename)with a pre-based string path to avoid Turbopack’s dynamicjoin()pattern analysis.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
📦 Build Size ComparisonSummary
Changes➕ Added Assets (1)
➖ Removed Assets (1)
|
|
cc @nodejs/nodejs-website fast-tracking as a hotfix. |
This PR is a hot-fix to Next.js complaining about Turbopack being unable to correctly statically analyze paths: