Skip to content

Latest commit

 

History

History
36 lines (19 loc) · 1.23 KB

readme.md

File metadata and controls

36 lines (19 loc) · 1.23 KB

Server Sent Events Reader

GoDoc Go Report Card codecov Go version Follow mojocn

This is a straightforward library illustrating the method to read Server Sent Events (SSE) stream from the Response.Body in Golang.

Usage

download the library using go get -u github.com/mojocn/sseread@latest

simple examples of how to use the library.

  1. read SSE by callback
  2. read SSE by channel
  3. cloudflare AI text generation example

Testing

# git clone https://github.com/mojocn/sseread.git && cd sseread
go test -v