From 7cc8c2a22b21d2aac0e6af27bd8ae436d9961c5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=82=E3=82=8F=E3=82=8F=E3=82=8F=E3=81=A8=E3=83=BC?= =?UTF-8?q?=E3=81=AB=E3=82=85?= <17376330+u1-liquid@users.noreply.github.com> Date: Wed, 6 Nov 2024 08:33:44 +0900 Subject: [PATCH] =?UTF-8?q?fix(misskey-js):=20WebSocket=E3=81=AE=E5=9E=8B?= =?UTF-8?q?=E5=AE=9A=E7=BE=A9=E3=82=92ReconnectingWebsocket=E3=81=AB?= =?UTF-8?q?=E4=BE=9D=E5=AD=98=E3=81=99=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB?= =?UTF-8?q?=20(misskey-dev#14850)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cherry-picked from ec4358d1e8c9a59a0702d19182c37d91510b3736 Co-authored-by: かっこかり <67428053+kakkokari-gtyih@users.noreply.github.com> --- packages/misskey-js/etc/misskey-js.api.md | 3 ++- packages/misskey-js/src/streaming.ts | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/misskey-js/etc/misskey-js.api.md b/packages/misskey-js/etc/misskey-js.api.md index b76d3517a..9d66cee2d 100644 --- a/packages/misskey-js/etc/misskey-js.api.md +++ b/packages/misskey-js/etc/misskey-js.api.md @@ -5,6 +5,7 @@ ```ts import { EventEmitter } from 'eventemitter3'; +import _ReconnectingWebsocket from 'reconnecting-websocket'; // Warning: (ae-forgotten-export) The symbol "components" needs to be exported by the entry point index.d.ts // @@ -3008,7 +3009,7 @@ export class Stream extends EventEmitter { constructor(origin: string, user: { token: string; } | null, options?: { - WebSocket?: any; + WebSocket?: _ReconnectingWebsocket.Options['WebSocket']; }); // (undocumented) close(): void; diff --git a/packages/misskey-js/src/streaming.ts b/packages/misskey-js/src/streaming.ts index 0f2685778..8016ec2fa 100644 --- a/packages/misskey-js/src/streaming.ts +++ b/packages/misskey-js/src/streaming.ts @@ -34,7 +34,7 @@ export default class Stream extends EventEmitter { private idCounter = 0; constructor(origin: string, user: { token: string; } | null, options?: { - WebSocket?: any; + WebSocket?: _ReconnectingWebsocket.Options['WebSocket']; }) { super();