@mainframe/transport-ws-node
v0.4.0
Published
WebSocket transport for node
Downloads
40
Keywords
Readme
transport-ws-node
WebSocket transport for node as a RxJS Subject
.
Installation
yarn add @mainframe/transport-ws-node
Usage
import wsTransport from '@mainframe/transport-ws-node'
const transport = wsTransport('ws://localhost')
transport.subcribe(console.log)
transport.next({ hello: 'transport' })
API
wsTransport()
Arguments
url: string
Returns Rx.Subject<T = any>
License
MIT