<ContextRoot />

undefined/undefined.svelte

""

Component ContextRoot examples :
code
- myContext

<script>
    /** read and set svelte context from component root */
    import ContextRooter  from "./ContextRooter.svelte";
    let myContextRef;
    setContext("myContext", {some:"data"});

    $: myContext = myContextRef

    $myContext.some = "other data"
</script>

<ContextRooter
    contextKey="Read and set svelte context from component root"
    bind:this={myContextRef} />
Api preview :