Skip to content

Commit b716de2

Browse files
committed
chore(): log error event in example
1 parent 71e8b5c commit b716de2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

examples/ws-public-spot-orderbook.ts

+3
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,9 @@ import {
5757
wsClient.on('reconnected', (data) => {
5858
console.log('ws has reconnected ', data?.wsKey);
5959
});
60+
wsClient.on('error', (data) => {
61+
console.error(`ws error: `, data?.wsKey, data);
62+
});
6063

6164
// Request subscription to the following symbol trade events:
6265
const symbols = ['BTCUSDT', 'ETHUSDT', 'BNBUSDT'];

0 commit comments

Comments
 (0)