Publishes application-wide values to Xenia adapters.
A provider renders a hidden element and wraps nothing, so it can sit anywhere on the page, typically once in the layout. When its value changes, LiveView patches the element and every adapter that consumes the provider receives the new value.
Example
<Xenia.Provider.provider name="theme" value={@theme} />Adapters receive these values by declaring:
consumes: ["theme"]The XeniaProvider hook must be registered, which createHooks/1 does.
Summary
Functions
Renders a hidden element that publishes value under name.