@sveltejs/adapter-vercel 5.7.0 → 5.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +11 -1
  2. package/package.json +4 -4
package/index.js CHANGED
@@ -137,9 +137,19 @@ const plugin = function (defaults = {}) {
137
137
  const result = await esbuild.build({
138
138
  entryPoints: [`${tmp}/edge.js`],
139
139
  outfile: `${dirs.functions}/${name}.func/index.js`,
140
- target: 'es2020', // TODO verify what the edge runtime supports
140
+ // minimum Node.js version supported is v14.6.0 that is mapped to ES2019
141
+ // https://edge-runtime.vercel.app/features/polyfills
142
+ // TODO verify the latest ES version the edge runtime supports
143
+ target: 'es2020',
141
144
  bundle: true,
142
145
  platform: 'browser',
146
+ conditions: [
147
+ // Vercel's Edge runtime key https://runtime-keys.proposal.wintercg.org/#edge-light
148
+ 'edge-light',
149
+ // re-include these since they are included by default when no conditions are specified
150
+ // https://esbuild.github.io/api/#conditions
151
+ 'module'
152
+ ],
143
153
  format: 'esm',
144
154
  external: [
145
155
  ...compatible_node_modules,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sveltejs/adapter-vercel",
3
- "version": "5.7.0",
3
+ "version": "5.7.1",
4
4
  "description": "A SvelteKit adapter that creates a Vercel app",
5
5
  "keywords": [
6
6
  "adapter",
@@ -35,14 +35,14 @@
35
35
  ],
36
36
  "dependencies": {
37
37
  "@vercel/nft": "^0.29.2",
38
- "esbuild": "^0.24.0"
38
+ "esbuild": "^0.25.2"
39
39
  },
40
40
  "devDependencies": {
41
41
  "@sveltejs/vite-plugin-svelte": "^5.0.1",
42
42
  "@types/node": "^18.19.48",
43
43
  "typescript": "^5.3.3",
44
- "vitest": "^3.0.1",
45
- "@sveltejs/kit": "^2.20.4"
44
+ "vitest": "^3.1.1",
45
+ "@sveltejs/kit": "^2.20.8"
46
46
  },
47
47
  "peerDependencies": {
48
48
  "@sveltejs/kit": "^2.4.0"