unws

Unified WebSocket API for Node.js, Bun and modern browsers.

MIT 11 个版本
安装
npm install unws
yarn add unws
pnpm add unws
bun add unws
README

unws npm

Unit Test

Unified WebSocket API for Node.js, Bun and modern browsers.

Install

npm i unws

Usage

import { WebSocket } from 'unws'

const ws = new WebSocket('ws://localhost:8080')

[!TIP] For Node.js v20.10.0 and above, the WebSocket global object is directly accessible without this package. See here.

Sponsors

License

MIT License © 2023-PRESENT 三咲智子

版本列表
0.3.2 2025-05-10
0.3.1 2025-03-09
0.3.0 2025-02-06
0.2.4 2023-08-01
0.2.3 2023-05-19
0.2.2 2023-04-19
0.2.1 2023-04-19
0.2.0 2023-04-19
0.1.1 2023-04-19
0.1.0 2023-04-19
0.0.0 2023-04-19