Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/twelve-cats-relax.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@astrojs/vercel': major
---

Updates Node v18 'retiring' notice to 'deprecated' for Vercel adapter.
Removes removeDate from 'deprecated' notice text.
10 changes: 2 additions & 8 deletions packages/integrations/vercel/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,13 +80,10 @@ const SUPPORTED_NODE_VERSIONS: Record<
}
| {
status: 'deprecated';
removal: Date;
}
> = {
18: {
status: 'retiring',
removal: new Date('September 1 2025'),
warnDate: new Date('October 1 2024'),
status: 'deprecated',
},
20: {
status: 'available',
Expand Down Expand Up @@ -775,13 +772,10 @@ function getRuntime(process: NodeJS.Process, logger: AstroIntegrationLogger): Ru
return `nodejs${major}.x`;
}
if (support.status === 'deprecated') {
const removeDate = new Intl.DateTimeFormat(undefined, {
dateStyle: 'long',
}).format(support.removal);
logger.warn(
`\n` +
`\tYour project is being built for Node.js ${major} as the runtime.\n` +
`\tThis version is deprecated by Vercel Serverless Functions, and scheduled to be disabled on ${removeDate}.\n` +
`\tThis version is deprecated by Vercel Serverless Functions.\n` +
`\tConsider upgrading your local version to 22.\n`,
);
return `nodejs${major}.x`;
Expand Down
Loading