Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/cryptix/gosseclient

Helper for Server-Sent Events
https://github.com/cryptix/gosseclient

Last synced: 1 day ago
JSON representation

Helper for Server-Sent Events

Awesome Lists containing this project

README

        

goSSEClient
===========

Helper for Server-Sent Events

Returns a channel of SSEvents.
```go
type SSEvent struct {
Id string
Data []byte
}
```

## Example
```go
sseEvent, err := goSSEClient.OpenSSEUrl(url)
if err != nil {
panic(err)
}

for ev := range sseEvent {
// do what you want with the event
}

```