Module

Jelly.Router

Package
purescript-jelly-router
Repository
yukikurage/purescript-jelly-router

#Router Source

class Router :: (Type -> Type) -> Constraintclass (MonadEffect m) <= Router m  where

Router m represents you can use routing in Monad m.

Members

Instances

#RouterR Source

type RouterR = { currentRoute :: Signal String, pushState :: String -> Effect Unit, replaceState :: String -> Effect Unit }

RouterR is a global values for RouterT.

#RouterT Source

newtype RouterT :: forall k. (k -> Type) -> k -> Typenewtype RouterT m a

RouterT is a Monad for Router.

Constructors

Instances

#runRouterT Source

runRouterT :: forall m a. MonadHooks m => RouterT m a -> m a

Run a RouterT.

#runMockRouterT Source

runMockRouterT :: forall m a. MonadHooks m => RouterT m a -> String -> m a

Run a RouterT outside of the browser. This is useful for SSG.

#initRouter Source

initRouter :: forall m. MonadHooks m => m RouterR

#routerLink' Source

routerLink' :: forall m. MonadEffect m => Router m => String -> Component m -> Component m

Same as routerLink, but without Props.

Modules
Jelly.Router