ws-web
v1.0.7
Published

Readme
ws-web
Use ws in the browser over Web Streams.
- No polyfills or dependencies.
- 144KB gzipped.
- Tested with Bun.
Installation
pnpm i ws-webUsage
import { WebSocket } from "ws-web";
const ws = new WebSocket("ws://fake.com", [], {
proxyStreams: (readable: ReadableStream, writable: WritableStream) => {
// TLS should be handled by the user. Raw data is exchanged here.
},
})Only the client is supported.
Development
bun i
bun demo
# Navigate to http://localhost:3000Building
bun i
bun package