SvelteRender v0.1.0 SvelteRender View Source
Svelte Renderer
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor.
Given the component_path
and props
, returns html.
Same as get_html/2
but wraps html in a div which is used
to hydrate svelte component on client side.
Starts the SvelteRender and workers.
Stops the SvelteRender and underlying node svelte render service
Link to this section Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
Given the component_path
and props
, returns html.
component_path
is the path to your svelte component module relative
to the render service.
props
is a map of props given to the component. Must be able to turn into
json
Same as get_html/2
but wraps html in a div which is used
to hydrate svelte component on client side.
This is the preferred function when using with Phoenix
component_path
is the path to your svelte component module relative
to the render service.
props
is a map of props given to the component. Must be able to turn into
json
Starts the SvelteRender and workers.
Options
:render_service_path
- (required) is the path to the svelte render service relative to your current working directory:pool_size
- (optional) the number of workers. Defaults to 4
Stops the SvelteRender and underlying node svelte render service