Function
layerWebSocket
(url: string, options?: {
readonly closeCodeIsError?: (code: number) => boolean
})
Source from the content-addressed store, hash-verified
| 286 | * @since 4.0.0 |
| 287 | */ |
| 288 | export const layerWebSocket = (url: string, options?: { |
| 289 | readonly closeCodeIsError?: (code: number) => boolean |
| 290 | }): Layer.Layer<Socket.Socket> => |
| 291 | Layer.effect(Socket.Socket, Socket.makeWebSocket(url, options)).pipe( |
| 292 | Layer.provide(layerWebSocketConstructor) |
| 293 | ) |
| 294 | |
| 295 | /** |
| 296 | * Provides the WebSocket constructor backed by `globalThis.WebSocket`. |
Callers
nothing calls this directly
Tested by
no test coverage detected