0.0.5 • Published 7 months ago
@svebcomponents/ssr v0.0.5
@svebcomponents/ssr
@svebcomponents/ssr is a collection of tools for server-side rendering web components with Svelte.
- Rollup Plugins
pluginGenerateSsrEntry- allows you to build server-side-renderable web components with Rollup
- Vite Plugins
vitePluginSvebcomponentsSsr- finds web components inside your svelte templates and replaces them with the
CustomElementWrapper.sveltecomponent CustomElementWrapper.svelteis a noop on the client, but on the server it will render the web component using theElementRendererprovided by the web component
- finds web components inside your svelte templates and replaces them with the
- Runtime Utils
- responsible for allowing you to render arbitrary web components in SvelteKit (or other vite based SSR frameworks) as long as they provide a
ElementRenderer installShim- installs
@lit-labs/ssr-dom-shimshims, in order to...- ensure your server doesn't explode when importing web components
- have a minimal working implementation of
customElementson the server so web components ctors can be registered with tag names
- installs
ElementRendererRegistry- a registry for registering
ElementRenderersthat should be used for rendering custom elements
- a registry for registering
SvelteCustomElementRenderer- base class for
ElementRenderersfor server-side rendering web components build withpluginGenerateSsrEntry(via@svebcomponents/build)
- base class for
- responsible for allowing you to render arbitrary web components in SvelteKit (or other vite based SSR frameworks) as long as they provide a