Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.
Releases
@cloudflare/[email protected]
Patch Changes
968171a: Fix autogenerated content also getting appended to the original public/_headers file
2115b9e: fix: implement route specific global scoping strategy
currently routes all share the same global scope, this can be problematic and cause
race conditions and failures
One example of this is the following code that is present in route function files:
and
this indicates that an in-memory global collection of the webpack chunks is shared by all routes,
this combined with the fact that chunks can have their own module state this can easily cause routes to conflict with each other at runtime.
So, in order to solve the above issue, all route functions are wrapped in a function which accepts as parameters, thus overrides, the
self
,globalThis
andglobal
symbols. The symbolswill be resolved with proxies that redirect setters to route-scoped in-memory maps and
getters to the above mentioned map's values and fallback to the original symbol values otherwise
(i.e.
globalThis
will be overridden by a proxy that, when setting values, sets them in a separatelocation and, when getting values, gets them from said location if present there or from the real
globalThis
otherwise)[email protected]