The docs from x/net/websocket still suggest gorilla or https://github.com/coder/websocket. I’ve used gorilla semi-recently and it was easy to use and reason about and I’d probably use it again. Check out this repo for a little demo I built using gorilla and client-side code that interfaces with it.
OK - but all that having been said, this project looks interesting:
Abstractions built on top of websockets. It has a JS lib to go with it, and Grafana is using it. The docs look good and the examples are extensive. Only downside is: no v1 yet so no compatibility guarantee (but I can’t imagine they are breaking things too often if Grafana is built on it!).
Here are some discussions about this topic with even more options:
https://www.reddit.com/r/golang/comments/zu80o0/gorillawebsocket_or_melody/
https://www.reddit.com/r/golang/comments/1cq61io/which_librarys_websocket_to_use/
In summary: I don’t think there is a definitive answer here, unfortunately. Pick something with a license that works for you and docs / examples that appeal to you.