View Source Loupe.PhoenixLiveView.Renderer behaviour (Loupe v0.9.0)
Module that is meant to be implemented to control how the component renders
Link to this section Summary
Functions
Determines how a value should be rendered for given renderer module
Gets a structure's link for a given renderer module
Link to this section Types
@type t() :: module()
Link to this section Callbacks
@callback render_type(any(), Loupe.Ecto.Context.assigns()) :: :ignore | {:ok, any()}
Link to this section Functions
@spec render_type(t() | nil, any(), Loupe.Ecto.Context.assigns()) :: any()
Determines how a value should be rendered for given renderer module
@spec struct_link(t() | nil, struct(), atom(), Loupe.Ecto.Context.assigns()) :: String.t() | {String.t(), Keyword.t()} | nil
Gets a structure's link for a given renderer module