From 60c5823ae12952c0f707a13a361edd9ec1646ab0 Mon Sep 17 00:00:00 2001 From: JuanM04 Date: Thu, 31 Mar 2022 15:37:33 -0300 Subject: [PATCH] Added some comments --- packages/integrations/vercel/src/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/integrations/vercel/src/index.ts b/packages/integrations/vercel/src/index.ts index ac3a4f9f05..8834d36626 100644 --- a/packages/integrations/vercel/src/index.ts +++ b/packages/integrations/vercel/src/index.ts @@ -37,6 +37,7 @@ export default function vercel(): AstroIntegration { 'astro:build:done': async ({ dir, routes }) => { const pagesDir = new URL('./server/pages/', dir); + // Convert server entry to CommonJS await esbuild.build({ entryPoints: [fileURLToPath(new URL(`./${ENTRYFILE}.mjs`, pagesDir))], outfile: fileURLToPath(new URL(`./${ENTRYFILE}.js`, pagesDir)), @@ -45,7 +46,6 @@ export default function vercel(): AstroIntegration { platform: 'node', target: 'node14', }); - await fs.rm(new URL(`./${ENTRYFILE}.mjs`, pagesDir)); // Routes Manifest