diff --git a/README.md b/README.md index 45712c07fcee35a037236b3ba63741d41d7646a7..921e8485195a83ca3dbc882c867d44ea94a1cd79 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ go get nhooyr.io/websocket ## Example -For a production quality example that shows off the full API, see the echo example on the godoc. +For a production quality example that shows off the full API, see the [echo example on the godoc](https://godoc.org/nhooyr.io/websocket#example-package--Echo). ### Server @@ -82,12 +82,12 @@ if err != nil { // ... } -_, err = ww.Write([]byte("hi")) +_, err = w.Write([]byte("hi")) if err != nil { // ... } -err = ww.Close() +err = w.Close() if err != nil { // ... } diff --git a/doc.go b/doc.go index 8f8697fdefc9da554d83c3214ba1ec5955cb7aef..22e6327378945db92ef16c2057a0fabdcebb90ab 100644 --- a/doc.go +++ b/doc.go @@ -2,7 +2,7 @@ // // See https://tools.ietf.org/html/rfc6455 // -// The examples are the best way to understand how to correctly use the library. +// The echo example is the best way to understand how to correctly use the library. // // Please see https://nhooyr.io/websocket for detailed design docs and a comparison with existing // libraries.