streaming-events-1.0.0: Client-side consumption of a ServerEvent.

CopyrightCopyright © 2019 Kadena LLC.
LicenseBSD-3-Clause
MaintainerColin Woodbury <colin@kadena.io>
Safe HaskellNone
LanguageHaskell2010

Network.Wai.EventSource.Streaming

Contents

Description

Client-side consumption of the ServerEvent type from wai-extra via the streaming ecosystem.

Synopsis

ServerEvent Stream

withEvents :: Request -> Manager -> (Stream (Of ServerEvent) IO () -> IO a) -> IO a Source #

A low-level wrapper around withResponse. Provides a simple, unending source of ServerEvents, presumably from an endpoint served via eventSourceAppIO or otherwise.

Since: 1.0.0

Attoparsec Parser

event :: Parser ServerEvent Source #

The underlying attoparsec Parser.

Since: 1.0.0