import { StandardWebSocketClient } from "https://deno.land/x/websocket@v0.1.2/mod.ts";
const endpoint = "ws://127.0.0.1:8080";
const ws = new StandardWebSocketClient(endpoint);
ws.on("open", function() {
console.log("ws connected!");
});
ws.on("message", function (message) {
console.log(message);
});
ws.send("something");
$ deno run --allow-net client.js
error: Uncaught SyntaxError: The requested module 'https://deno.land/x/websocket@v0.1.2/mod.ts' does not provide an export named 'WebSocketClient'
import { WebSocketClient, StandardWebSocketClient } from "https://deno.land/x/websocket@v0.1.2/mod.ts";
~~~~~~~~~~~~~~~
at <anonymous> (file:///home/user/project/client.js:1:10)