A WebSocket client implementation.
```rust use websockets::{WebSocket, WebSocketError};
async fn main() { let mut ws = WebSocket::connect("wss://echo.websocket.org/").await.unwrap(); ws.sendtext("foo".tostring(), false, true).await.unwrap(); ws.receive().await.unwrap(); ws.close(None).await.unwrap(); } ```
The [WebSocket
] type manages the WebSocket connection.
Use it to connect, send, and receive data.
Data is sent and received through [Frame
]s.
See these types for additional information on how to use them.