Skip to content

Commit c1efa15

Browse files
committed
feat: update server-functions-plugin to v1.134
1 parent 7c8b6f3 commit c1efa15

3 files changed

Lines changed: 40 additions & 24 deletions

File tree

packages/start/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
"@babel/traverse": "^7.28.3",
4040
"@babel/types": "^7.28.5",
4141
"@solidjs/meta": "^0.29.4",
42-
"@tanstack/server-functions-plugin": "^1.133.11",
42+
"@tanstack/server-functions-plugin": "1.134.5",
4343
"@types/babel__traverse": "^7.28.0",
4444
"@types/micromatch": "^4.0.9",
4545
"cookie-es": "^2.0.0",

packages/start/src/config/index.ts

Lines changed: 26 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -178,16 +178,32 @@ export function solidStart(options?: SolidStartOptions): Array<PluginOption> {
178178
// This is the ID that will be available to look up and import
179179
// our server function manifest and resolve its module
180180
manifestVirtualImportId: VIRTUAL_MODULES.serverFnManifest,
181-
client: {
182-
envName: VITE_ENVIRONMENTS.client,
183-
getRuntimeCode: () =>
184-
`import { createServerReference } from "${normalize(
185-
fileURLToPath(new URL("../server/server-runtime", import.meta.url)),
186-
)}"`,
187-
replacer: (opts) =>
188-
`createServerReference(${() => {}}, '${opts.functionId}', '${opts.extractedFilename}')`,
189-
},
190-
server: {
181+
directive: "use server",
182+
callers: [
183+
{
184+
envConsumer: "client",
185+
envName: VITE_ENVIRONMENTS.client,
186+
getRuntimeCode: () =>
187+
`import { createServerReference } from "${normalize(
188+
fileURLToPath(new URL("../server/server-runtime", import.meta.url)),
189+
)}"`,
190+
replacer: (opts) =>
191+
`createServerReference(${() => {}}, '${opts.functionId}', '${opts.extractedFilename}')`,
192+
},
193+
{
194+
envConsumer: "server",
195+
envName: VITE_ENVIRONMENTS.server,
196+
getRuntimeCode: () =>
197+
`import { createServerReference } from '${normalize(
198+
fileURLToPath(
199+
new URL("../server/server-fns-runtime", import.meta.url),
200+
),
201+
)}'`,
202+
replacer: (opts) =>
203+
`createServerReference(${opts.fn}, '${opts.functionId}', '${opts.extractedFilename}')`,
204+
}
205+
],
206+
provider: {
191207
envName: VITE_ENVIRONMENTS.server,
192208
getRuntimeCode: () =>
193209
`import { createServerReference } from '${normalize(

pnpm-lock.yaml

Lines changed: 13 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)