Documentation ¶
Overview ¶
Package client implements a server-sent event API client.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidSubscribeArgs = errors.New("must provides at leat a channel or a callback func in order to subscribe")
ErrInvalidSubscribeArgs is returned when a client tries to subscribe without a channel or a callback
Functions ¶
This section is empty.
Types ¶
type Event ¶
type Event struct { Event string // Type of the event (i.e. "hearbeat", or you custom event type) Data []byte // Data field }
Event holds the event fields
Click to show internal directories.
Click to hide internal directories.