Versions in this module Expand all Collapse all v0 v0.10.1 Oct 31, 2026 v0.10.0 Oct 31, 2026 v0.9.0 Oct 30, 2026 v0.8.0 Oct 30, 2026 v0.7.0 Oct 28, 2026 v0.6.0 Oct 27, 2026 v0.5.0 Oct 25, 2026 v0.4.0 Oct 10, 2026 v0.3.0 Oct 10, 2026 v0.2.0 Oct 7, 2026 v0.1.0 Oct 7, 2026 Changes in this version + const CodeDecode + const CodeUnknownRoute + const CodeValidation + const KindHTML + const KindText + const StatusReauth + func Decode[T any](raw json.RawMessage) (T, error) + func ParseValue[T any](s string) (T, error) + type AckMsg struct + RouteKey string + T string + Var string + type Binding struct + Kind string + Value string + func HTMLBinding(markup string) Binding + func TextBinding(text string) Binding + type Broadcast struct + func NewBroadcast[V any]() *Broadcast[V] + func (b *Broadcast[V]) Publish(v V) + func (b *Broadcast[V]) Subscribe() *BroadcastSub[V] + func (b *Broadcast[V]) TotalSubs() int + type BroadcastSub struct + func (s *BroadcastSub[V]) Close() + func (s *BroadcastSub[V]) Updates() <-chan V + type CallMsg struct + Args json.RawMessage + ID uint32 + Name string + RouteKey string + T string + type Conn struct + func Accept(w http.ResponseWriter, r *http.Request) (*Conn, error) + func (c *Conn) Ack(ctx context.Context, msg WriteMsg) + func (c *Conn) Close(code websocket.StatusCode, reason string) + func (c *Conn) Enqueue(key string, b Binding) + func (c *Conn) ReadFrames(ctx context.Context, onWrite func(WriteMsg), onCall func(CallMsg)) error + func (c *Conn) Reject(ctx context.Context, msg WriteMsg, text, code string) + func (c *Conn) Send(ctx context.Context, v any) error + func (c *Conn) SendLoop(ctx context.Context) error + type ErrMsg struct + Code string + Msg string + RouteKey string + T string + Var string + func NewErr(routeKey, varName, text, code string) ErrMsg + type FailMsg struct + ID uint32 + Msg string + Status int + T string + func NewFail(id uint32, status int, text string) FailMsg + type InitMsg struct + Bindings map[string]Binding + T string + func NewInit(bindings map[string]Binding) InitMsg + type PatchMsg struct + Key string + T string + type ResultMsg struct + ID uint32 + T string + Value json.RawMessage + func NewResult(id uint32, value json.RawMessage) ResultMsg + type Topic struct + func NewTopic[K comparable, V any]() *Topic[K, V] + func (t *Topic[K, V]) Len() int + func (t *Topic[K, V]) Publish(key K, v V) + func (t *Topic[K, V]) Subscribe(key K) *TopicSub[V] + func (t *Topic[K, V]) TotalSubs() int + type TopicSub struct + func (s *TopicSub[V]) Close() + func (s *TopicSub[V]) Updates() <-chan V + type WriteMsg struct + RouteKey string + T string + Value json.RawMessage + Var string