ParamsHooks
trait ParamsHooks[Msg, Model]The dynamic params hooks of one LiveView lifecycle.
Defined by scalive.ParamsHooks. View source (scalive/api/src/scalive/lifecycle/Hooks.scala:368-383)
Methods2
attach
def attach(id: String)(hook: (Model, zio.http.URL, ParamsContext[Msg, Model]) => zio.package.Task[LiveHookResult[Model]]): zio.package.Task[Unit]Attaches hook under id, to run with the new URL before handleParams.
Every LiveView runs these hooks after mount and each time its URL changes; a nested LiveView
sees the URL of its page. A Routed view skips them when the URL does not decode
into its parameters. A halt skips later hooks and handleParams. Attaching an id that is
already attached replaces that hook in place.
Defined by scalive.ParamsHooks.attach. View source (scalive/api/src/scalive/lifecycle/Hooks.scala:376-380)
detach
def detach(id: String): zio.package.Task[Unit]Detaches the dynamic hook attached under id, if any. Static hooks cannot be detached.
Defined by scalive.ParamsHooks.detach. View source (scalive/api/src/scalive/lifecycle/Hooks.scala:383-383)