Skip to content

Commit

Permalink
docs: update ssr (#8987)
Browse files Browse the repository at this point in the history
  • Loading branch information
bluwy committed Jul 12, 2022
1 parent 45b8b53 commit 8c52867
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 11 deletions.
10 changes: 3 additions & 7 deletions docs/config/ssr-options.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,16 @@
# SSR Options

- **Related:** [SSR Externals](/guide/ssr#ssr-externals)

:::warning Experimental
SSR options may be adjusted in minor releases.
:::

## ssr.external

- **Type:** `string[]`
- **Related:** [SSR Externals](/guide/ssr#ssr-externals)

Force externalize dependencies for SSR.

## ssr.noExternal

- **Type:** `string | RegExp | (string | RegExp)[] | true`
- **Related:** [SSR Externals](/guide/ssr#ssr-externals)

Prevent listed dependencies from being externalized for SSR. If `true`, no dependencies are externalized.

Expand All @@ -27,8 +23,8 @@ Build target for the SSR server.

## ssr.format

- **Experimental**
- **Type:** `'esm' | 'cjs'`
- **Default:** `esm`
- **Experimental**

Build format for the SSR server. Since Vite v3 the SSR build generates ESM by default. `'cjs'` can be selected to generate a CJS build, but it isn't recommended. The option is left marked as experimental to give users more time to update to ESM. CJS builds requires complex externalization heuristics that aren't present in the ESM format.
4 changes: 0 additions & 4 deletions docs/guide/ssr.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
# Server-Side Rendering

:::warning Experimental
SSR support is still experimental and you may encounter bugs and unsupported use cases. Proceed at your own risk.
:::

:::tip Note
SSR specifically refers to front-end frameworks (for example React, Preact, Vue, and Svelte) that support running the same application in Node.js, pre-rendering it to HTML, and finally hydrating it on the client. If you are looking for integration with traditional server-side frameworks, check out the [Backend Integration guide](./backend-integration) instead.

Expand Down

0 comments on commit 8c52867

Please sign in to comment.