A lightweight WebSocket client for connecting to Bilibili live danmaku (bullet comments) streams. Version 0.0.3, early-stage release with no regular update cadence. Provides three public APIs ($start, $destroy, $subscribe) to manage the WebSocket connection and subscribe to messages. Intended for browser use (Chrome recommended) with native WebSocket. No TypeScript typings included. Users must configure their own nginx proxy to relay Bilibili's danmaku WebSocket service, as the author's hosted proxy has expired.
npm install bilibili-websocketNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Connects to a Bilibili live room and logs incoming danmaku messages.
Configure your own nginx reverse proxy to wss://broadcastlv.chat.bilibili.com/sub or use a direct WebSocket connection if allowed.
Pick a popular live room ID (e.g., 7623885) for testing.
Ensure you import BILIWS correctly (import BILIWS from 'bilibili-websocket') and that the script is loaded as a module.
Set up your own nginx proxy or provide a direct WebSocket URL to Bilibili's danmaku server.
No dependency data recorded yet.