API reference / @evolu/svelte / index.svelte / appOwnerState
Function: appOwnerState()
function appOwnerState<Schema>(evolu): object;
Defined in: index.svelte.ts:133
Get the AppOwner promise that resolves when available.
Example
import { appOwnerState } from "@evolu/svelte";
const owner = appOwnerState(evolu);
// use owner.current in your Svelte templates
// it will be undefined initially and set once the promise resolves
Type Parameters
| Type Parameter |
|---|
Schema extends Readonly<Record<string, Readonly<Record<string, Type<any, any, any, any, any, any>>>>> |
Parameters
| Parameter | Type |
|---|---|
evolu | Evolu<Schema> |
Returns
object
| Name | Type | Defined in |
|---|---|---|
current | | AppOwner | undefined | index.svelte.ts:136 |