You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- JSON and protobuf helpers in the [wsjson](https://godoc.org/nhooyr.io/websocket/wsjson) and [wspb](https://godoc.org/nhooyr.io/websocket/wspb) subpackages
18
+
- Thorough tests with [90% coverage](https://coveralls.io/github/nhooyr/websocket)
- JSON and protobuf helpers in the [wsjson](https://pkg.go.dev/nhooyr.io/websocket/wsjson) and [wspb](https://pkg.go.dev/nhooyr.io/websocket/wspb) subpackages
For a production quality example that demonstrates the complete API, see the [echo example](https://godoc.org/nhooyr.io/websocket#example-package--Echo).
35
+
For a production quality example that demonstrates the complete API, see the
36
+
[echo example](./examples/echo).
36
37
37
-
For a full stack example, see [./chat-example](./chat-example).
38
+
For a full stack example, see the [chatexample](./examples/chat).
- Compare godoc of [nhooyr.io/websocket](https://godoc.org/nhooyr.io/websocket) with [gorilla/websocket](https://godoc.org/github.com/gorilla/websocket) side by side.
- Compare godoc of [nhooyr.io/websocket](https://pkg.go.dev/nhooyr.io/websocket) with [gorilla/websocket](https://pkg.go.dev/github.com/gorilla/websocket) side by side.
- Gorilla writes directly to a net.Conn and so duplicates features of net/http.Client.
104
105
- Concurrent writes
105
106
- Close handshake ([gorilla/websocket#448](https://github.com/gorilla/websocket/issues/448))
106
-
- Idiomatic [ping pong](https://godoc.org/nhooyr.io/websocket#Conn.Ping) API
107
+
- Idiomatic [ping pong](https://pkg.go.dev/nhooyr.io/websocket#Conn.Ping) API
107
108
- Gorilla requires registering a pong callback before sending a Ping
108
109
- Can target Wasm ([gorilla/websocket#432](https://github.com/gorilla/websocket/issues/432))
109
-
- Transparent message buffer reuse with [wsjson](https://godoc.org/nhooyr.io/websocket/wsjson) and [wspb](https://godoc.org/nhooyr.io/websocket/wspb) subpackages
110
+
- Transparent message buffer reuse with [wsjson](https://pkg.go.dev/nhooyr.io/websocket/wsjson) and [wspb](https://pkg.go.dev/nhooyr.io/websocket/wspb) subpackages
110
111
-[1.75x](https://github.com/nhooyr/websocket/releases/tag/v1.7.4) faster WebSocket masking implementation in pure Go
111
112
- Gorilla's implementation is slower and uses [unsafe](https://golang.org/pkg/unsafe/).
112
113
- Full [permessage-deflate](https://tools.ietf.org/html/rfc7692) compression extension support
113
114
- Gorilla only supports no context takeover mode
114
-
- We use [klauspost/compress](https://github.com/klauspost/compress) for much lower memory usage ([gorilla/websocket#203](https://github.com/gorilla/websocket/issues/203))
- We use a vendored [klauspost/compress](https://github.com/klauspost/compress) for much lower memory usage ([gorilla/websocket#203](https://github.com/gorilla/websocket/issues/203))
0 commit comments