# `LiveSvelte.SSR.ViteJS`
[🔗](https://github.com/woutdp/live_svelte/blob/v0.18.0/lib/ssr/vite_js.ex#L1)

Implements SSR by making a POST request to `http://{:vite_host}/ssr_render`.

`ssr_render` is implemented as a Vite plugin. Add it to the `vite.config.js` plugins section:

```javascript
import liveSveltePlugin from "live_svelte/vitePlugin"

export default {
  plugins: [liveSveltePlugin()],
  // ...
}
```

## Configuration

In `config/dev.exs`:

```elixir
config :live_svelte, ssr_module: LiveSvelte.SSR.ViteJS
config :live_svelte, vite_host: "http://localhost:5173"
```

# `render`

# `vite_path`

Returns a path relative to the configured Vite JS host.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
