@sveltejs/adapter-vercel 5.10.0 → 5.10.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.
- package/index.d.ts +2 -0
- package/index.js +9 -0
- package/package.json +2 -2
package/index.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ export interface ServerlessConfig {
|
|
|
7
7
|
/**
|
|
8
8
|
* Whether to use [Edge Functions](https://vercel.com/docs/concepts/functions/edge-functions) (`'edge'`) or [Serverless Functions](https://vercel.com/docs/concepts/functions/serverless-functions) (`'nodejs18.x'`, `'nodejs20.x'` etc).
|
|
9
9
|
* @default Same as the build environment
|
|
10
|
+
* @deprecated
|
|
10
11
|
*/
|
|
11
12
|
runtime?: `nodejs${number}.x`;
|
|
12
13
|
/**
|
|
@@ -74,6 +75,7 @@ type ImagesConfig = {
|
|
|
74
75
|
contentDispositionType?: string;
|
|
75
76
|
};
|
|
76
77
|
|
|
78
|
+
/** @deprecated */
|
|
77
79
|
export interface EdgeConfig {
|
|
78
80
|
/**
|
|
79
81
|
* Whether to use [Edge Functions](https://vercel.com/docs/concepts/functions/edge-functions) (`'edge'`) or [Serverless Functions](https://vercel.com/docs/concepts/functions/serverless-functions) (`'nodejs18.x'`, `'nodejs20.x'` etc).
|
package/index.js
CHANGED
|
@@ -131,12 +131,21 @@ const plugin = function (defaults = {}) {
|
|
|
131
131
|
}
|
|
132
132
|
}
|
|
133
133
|
|
|
134
|
+
let warned = false;
|
|
135
|
+
|
|
134
136
|
/**
|
|
135
137
|
* @param {string} name
|
|
136
138
|
* @param {import('./index.js').EdgeConfig} config
|
|
137
139
|
* @param {import('@sveltejs/kit').RouteDefinition<import('./index.js').EdgeConfig>[]} routes
|
|
138
140
|
*/
|
|
139
141
|
async function generate_edge_function(name, config, routes) {
|
|
142
|
+
if (!warned) {
|
|
143
|
+
warned = true;
|
|
144
|
+
builder.log.warn(
|
|
145
|
+
`The \`runtime: 'edge'\` option is deprecated, and will be removed in a future version of adapter-vercel`
|
|
146
|
+
);
|
|
147
|
+
}
|
|
148
|
+
|
|
140
149
|
const tmp = builder.getBuildDirectory(`vercel-tmp/${name}`);
|
|
141
150
|
const relativePath = path.posix.relative(tmp, builder.getServerDirectory());
|
|
142
151
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sveltejs/adapter-vercel",
|
|
3
|
-
"version": "5.10.
|
|
3
|
+
"version": "5.10.1",
|
|
4
4
|
"description": "A SvelteKit adapter that creates a Vercel app",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"adapter",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"@types/node": "^18.19.119",
|
|
43
43
|
"typescript": "^5.3.3",
|
|
44
44
|
"vitest": "^3.2.3",
|
|
45
|
-
"@sveltejs/kit": "^2.
|
|
45
|
+
"@sveltejs/kit": "^2.33.0"
|
|
46
46
|
},
|
|
47
47
|
"peerDependencies": {
|
|
48
48
|
"@sveltejs/kit": "^2.4.0"
|