SessionLive

dev.cheleb.ziolaminartapir.SessionLive
class SessionLive[UserToken <: WithToken](using x$1: JsonCodec[UserToken]) extends Session[UserToken]

Attributes

Graph
Supertypes
trait Session[UserToken]
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def apply[A](withSession: => A)(withoutSession: => A): Signal[Option[A]]
def clearUserState(): Unit
def getUserState: Option[UserToken]
def isActive: Boolean
def loadUserState(): Unit
def setUserState(token: UserToken): Unit
def whenActive[A](callback: => A): Signal[Option[A]]

This method is used to produce an Option when the user is active.

This method is used to produce an Option when the user is active.

Convenient to render an element only when the user is active.

See ChildReceiver.maybe for more information.

Attributes

Concrete fields

val userState: Var[Option[UserToken]]