package
Version:
v0.0.8
Opens a new window with list of versions in this module.
Published: Jun 20, 2025
License: MIT
Opens a new window with license information.
Imports: 5
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
HandleSSE handles the SSE connection for a client
Client represents a connected SSE client
type Event struct {
Type string `json:"type"`
Content string `json:"content"`
}
Event represents a server-sent event
type EventBus struct {
Register chan *Client
Unregister chan *Client
}
EventBus manages all SSE clients and message distribution
NewEventBus creates a new event bus instance
GetClient returns a client by ID
Run starts the event bus loop
Source Files
¶
Click to show internal directories.
Click to hide internal directories.