From cb5a6eb3d4368de8b5f7739e70dc8f42103d87ac Mon Sep 17 00:00:00 2001 From: ruslansafin Date: Fri, 22 Oct 2021 13:07:27 +0300 Subject: [PATCH] A new parameter types fix --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 9732682..71a56fb 100644 --- a/README.md +++ b/README.md @@ -139,9 +139,9 @@ type UseWebSocket = ( } = {}, shouldConnect: boolean = true, ): { - sendMessage: (message: string, keep = boolean = true) => void, + sendMessage: (message: string, keep: boolean = true) => void, //jsonMessage must be JSON-parsable - sendJsonMessage: (jsonMessage: any, keep = boolean = true) => void, + sendJsonMessage: (jsonMessage: any, keep: boolean = true) => void, //null before first received message lastMessage: WebSocketEventMap['message'] | null, //null before first received message. If message.data is not JSON parsable, then this will be a static empty object