Function hasContext

  • Checks whether a given key has been set in the context of a parent component. Must be called during component initialisation.

    https://svelte.dev/docs/svelte#hascontext

    Parameters

    • key: any

    Returns boolean