diff options
Diffstat (limited to 'examples/ssr')
-rw-r--r-- | examples/ssr/package.json | 8 | ||||
-rw-r--r-- | examples/ssr/src/api.ts | 6 |
2 files changed, 9 insertions, 5 deletions
diff --git a/examples/ssr/package.json b/examples/ssr/package.json index 370e79972..1688374f6 100644 --- a/examples/ssr/package.json +++ b/examples/ssr/package.json @@ -9,15 +9,15 @@ "server": "node server/server.mjs" }, "devDependencies": { - "@astrojs/svelte": "^0.0.2", "@astrojs/node": "^0.0.2", - "astro": "^0.25.4", - "concurrently": "^7.0.0", + "@astrojs/svelte": "^0.0.2", + "astro": "^0.26.0", + "concurrently": "^7.1.0", "lightcookie": "^1.0.25", "unocss": "^0.15.6", "vite-imagetools": "^4.0.3" }, "dependencies": { - "svelte": "^3.46.4" + "svelte": "^3.46.6" } } diff --git a/examples/ssr/src/api.ts b/examples/ssr/src/api.ts index 82c82a190..939130506 100644 --- a/examples/ssr/src/api.ts +++ b/examples/ssr/src/api.ts @@ -21,7 +21,11 @@ function getOrigin(request: Request): string { return new URL(request.url).origin.replace('localhost', '127.0.0.1'); } -async function get<T>(incomingReq: Request, endpoint: string, cb: (response: Response) => Promise<T>): Promise<T> { +async function get<T>( + incomingReq: Request, + endpoint: string, + cb: (response: Response) => Promise<T> +): Promise<T> { const response = await fetch(`${getOrigin(incomingReq)}${endpoint}`, { credentials: 'same-origin', }); |