mirror of
https://github.com/cloudflare/vinext.git
synced 2026-05-09 08:25:34 +02:00
[PR #509] [MERGED] chore: add missing __vinext globals to global.d.ts #631
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#631
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?
📋 Pull Request Information
Original PR: https://github.com/cloudflare/vinext/pull/509
Author: @james-elicx
Created: 3/12/2026
Status: ✅ Merged
Merged: 3/12/2026
Merged by: @james-elicx
Base:
main← Head:fix/global-types-vinext-missing-globals📝 Commits (1)
9465827add missing __vinext globals to global.d.ts and remove (req as any) casts📊 Changes
2 files changed (+25 additions, -2 deletions)
View changed files
📝
packages/vinext/src/global.d.ts(+23 -0)📝
packages/vinext/src/index.ts(+2 -2)📄 Description
Summary
process.env.__VINEXT_BUILD_IDto theProcessEnvinterface — it was already injected via Vitedefineat build time and read in 6+ source files, but was missing from the declaration.declare module "node:http"augmentation forIncomingMessage.__vinextRewriteStatus— previously accessed via(req as any)in two places inindex.ts; both casts are now removed.What was already covered
All
__VINEXT_RSC_*,__VINEXT_ROOT__,__VINEXT_APP__, locale, manifest, and error-handler globals were already declared inglobal.d.ts. The__vinext_scrollX/__vinext_scrollYhistory-state properties don't need a global declaration sincehistory.stateis typedanyin the DOM — the existing inline casts at those sites are appropriate.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.