Closed sharanwj closed 1 day ago
Hi,
WebSocket
should be available in your environment. If necessary, you can simply polyfill it.
Let me know if you need any further adjustments!
Closing due to lack of responses. You may reopen the issue if you need to.
Regards, dxLink team
Getting error when creating a client -
Error - this.socket = new WebSocket(this.url) ^ ReferenceError: WebSocket is not defined at WebSocketConnector.start (file:///Users/xyz/tt/node_modules/@dxfeed/dxlink-websocket-client/src/connector.ts:23:23)
https://github.com/dxFeed/dxLink/blob/1eaefd9341ddde5ba0cb4b4690f84ead20fa073e/dxlink-javascript/dxlink-websocket-client/src/connector.ts#L23
I added this import in connector class which fixed the issue locally for me -
import WebSocket from 'ws';