JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 530
  • Score
    100M100P100Q92596F
  • License MIT

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

Package Exports

  • unws
  • unws/package.json

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 三咲智子