From 91d4572c9a7ba4a31f282e5e1bb94282f413b250 Mon Sep 17 00:00:00 2001 From: Leander Gilles Date: Fri, 12 Apr 2024 00:24:15 +0200 Subject: [PATCH] don't spread astroGlobalPartial into astroGlobalCombined this change improves the server stress latency of the benchmark by about 25% --- packages/astro/src/core/render-context.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/astro/src/core/render-context.ts b/packages/astro/src/core/render-context.ts index 4155de863db6..eb05df6f5db6 100644 --- a/packages/astro/src/core/render-context.ts +++ b/packages/astro/src/core/render-context.ts @@ -264,7 +264,8 @@ export class RenderContext { // `Astro.self` is added by the compiler const astroGlobalCombined: Omit = { - ...astroGlobalPartial, + generator: astroGlobalPartial.generator, + glob: astroGlobalPartial.glob, cookies, get clientAddress() { return renderContext.clientAddress();