Safe Haskell | None |
---|---|
Language | Haskell98 |
Documentation
data RawWebSocket t a Source #
RawWebSocket | |
|
type WebSocket t = RawWebSocket t ByteString Source #
data WebSocketConfig t a Source #
WebSocketConfig | |
|
Instances
Reflex t => Default (WebSocketConfig t a) Source # | |
Defined in Reflex.Dom.WebSocket def :: WebSocketConfig t a # |
webSocket :: (MonadJSM m, MonadJSM (Performable m), HasJSContext m, PerformEvent t m, TriggerEvent t m, PostBuild t m, IsWebSocketMessage a) => Text -> WebSocketConfig t a -> m (WebSocket t) Source #
webSocket' :: (MonadJSM m, MonadJSM (Performable m), HasJSContext m, PerformEvent t m, TriggerEvent t m, PostBuild t m, IsWebSocketMessage a) => Text -> WebSocketConfig t a -> (Either ByteString JSVal -> JSM b) -> m (RawWebSocket t b) Source #
textWebSocket :: (IsWebSocketMessage a, MonadJSM m, MonadJSM (Performable m), HasJSContext m, PostBuild t m, TriggerEvent t m, PerformEvent t m, MonadHold t m, Reflex t) => Text -> WebSocketConfig t a -> m (RawWebSocket t Text) Source #
jsonWebSocket :: (ToJSON a, FromJSON b, MonadJSM m, MonadJSM (Performable m), HasJSContext m, PostBuild t m, TriggerEvent t m, PerformEvent t m, MonadHold t m, Reflex t) => Text -> WebSocketConfig t a -> m (RawWebSocket t (Maybe b)) Source #
webSocketConfig_close :: forall t a. Lens' (WebSocketConfig t a) (Event t (Word, Text)) Source #
webSocketConfig_protocols :: forall t a. Lens' (WebSocketConfig t a) [Text] Source #
webSocketConfig_reconnect :: forall t a. Lens' (WebSocketConfig t a) Bool Source #
webSocketConfig_send :: forall t a. Lens' (WebSocketConfig t a) (Event t [a]) Source #
webSocket_close :: forall t a. Lens' (RawWebSocket t a) (Event t (Bool, Word, Text)) Source #
webSocket_error :: forall t a. Lens' (RawWebSocket t a) (Event t ()) Source #
webSocket_open :: forall t a. Lens' (RawWebSocket t a) (Event t ()) Source #
webSocket_recv :: forall t a. Lens' (RawWebSocket t a) (Event t a) Source #