RouterCtlF

abstract class RouterCtlF[F[_], Route]

Router controller. A client API to the router.

Router controller. A client API to the router.

Type Params
Route

A data type that indicates a route that can be navigated to.

Companion
object
class Object
trait Matchable
class Any
class Contramap[F, A, B]
class ModCB[F, A]
class AltEffect[F, G, A]

Value members

Abstract methods

def pathFor(route: Route): Path
def refresh: F[Unit]
def set(route: Route, via: SetRouteVia): F[Unit]

Concrete methods

final def contramap[B](f: B => Route): RouterCtlF[F, B]
final def narrow[B <: Route]: RouterCtlF[F, B]
final def onLinkClick(route: Route): ReactMouseEvent => Option[F[Unit]]
final def onSet(f: (Route, F[Unit]) => F[Unit]): RouterCtlF[F, Route]

Change the behaviour of set and all derivatives.

Change the behaviour of set and all derivatives.

For example, this can be used to set a component's state immediately before setting a new route.

final def onSet(f: F[Unit] => F[Unit]): RouterCtlF[F, Route]

Change the behaviour of set and all derivatives.

Change the behaviour of set and all derivatives.

For example, this can be used to set a component's state immediately before setting a new route.

final def onSetRun(f: F[Unit]): RouterCtlF[F, Route]

Return a new version of this that executes the specified callback after setting new routes.

Return a new version of this that executes the specified callback after setting new routes.

final def set(route: Route): F[Unit]
final def setEH(route: Route): ReactEvent => F[Unit]
final def setOnClick(route: Route): TagMod
final def setOnLinkClick(route: Route): TagMod
final def urlFor(route: Route): AbsUrl
def withEffect[G[_]](G: Sync[G]): RouterCtlF[G, Route]

Deprecated methods

@deprecated("Use .onSetRun(callback).setOnClick(route)", "forever")
final def setOnClick(route: Route, callback: F[Unit]): TagMod
Deprecated
@deprecated("Use .onSetRun(callback).setOnLinkClick(route)", "forever")
final def setOnLinkClick(route: Route, callback: F[Unit]): TagMod
Deprecated