Skip to content

Commit c4be25b

Browse files
Sync kit docs (#1459)
sync kit docs Co-authored-by: svelte-docs-bot[bot] <196124396+svelte-docs-bot[bot]@users.noreply.github.com>
1 parent 498693a commit c4be25b

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

apps/svelte.dev/content/docs/kit/25-build-and-deploy/60-adapter-cloudflare.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,11 @@ When deploying your application, the server generated by SvelteKit is bundled in
185185

186186
### Accessing the file system
187187

188-
You can't use `fs` in Cloudflare Workers — you must [prerender](page-options#prerender) the routes in question.
188+
You can't use `fs` in Cloudflare Workers.
189+
190+
Instead, use the [`read`]($app-server#read) function from `$app/server` to access your files. It works by fetching the file from the deployed public assets location.
191+
192+
Alternatively, you can [prerender](page-options#prerender) the routes in question.
189193

190194
## Migrating from Workers Sites
191195

apps/svelte.dev/content/docs/kit/25-build-and-deploy/80-adapter-netlify.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,6 @@ Additionally, you can add your own Netlify functions by creating a directory for
118118

119119
You can't use `fs` in edge deployments.
120120

121-
You _can_ use it in serverless deployments, but it won't work as expected, since files are not copied from your project into your deployment. Instead, use the [`read`]($app-server#read) function from `$app/server` to access your files. `read` does not work inside edge deployments (this may change in future).
121+
You _can_ use it in serverless deployments, but it won't work as expected, since files are not copied from your project into your deployment. Instead, use the [`read`]($app-server#read) function from `$app/server` to access your files. It also works inside edge deployments by fetching the file from the deployed public assets location.
122122

123123
Alternatively, you can [prerender](page-options#prerender) the routes in question.

apps/svelte.dev/content/docs/kit/25-build-and-deploy/90-adapter-vercel.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,6 @@ Projects created before a certain date may default to using an older Node versio
195195

196196
You can't use `fs` in edge functions.
197197

198-
You _can_ use it in serverless functions, but it won't work as expected, since files are not copied from your project into your deployment. Instead, use the [`read`]($app-server#read) function from `$app/server` to access your files. `read` does not work inside routes deployed as edge functions (this may change in future).
198+
You _can_ use it in serverless functions, but it won't work as expected, since files are not copied from your project into your deployment. Instead, use the [`read`]($app-server#read) function from `$app/server` to access your files. It also works inside routes deployed as edge functions by fetching the file from the deployed public assets location.
199199

200200
Alternatively, you can [prerender](page-options#prerender) the routes in question.

0 commit comments

Comments
 (0)