From ab715d0ef710204f672e4c2a83a7ecfdce0f25c3 Mon Sep 17 00:00:00 2001 From: ACoolName Date: Mon, 27 May 2024 23:36:56 +0300 Subject: [PATCH] errors --- src/terminal.tsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/terminal.tsx b/src/terminal.tsx index 9f9f92e..23f5644 100644 --- a/src/terminal.tsx +++ b/src/terminal.tsx @@ -47,8 +47,12 @@ function TerminalComponent (p: {websocket: string|null}) { const socket = new WebSocket(websocket); + socket.onerror = (ev)=>{ + console.log(ev) + } + socket.addEventListener('open', () => { - // socket.send(JSON.stringify({CommandType: 'resize', Arguments: [terminal.current?.rows, terminal.current?.cols]})); + socket.send(JSON.stringify({CommandType: 'resize', Arguments: [terminal.current?.rows, terminal.current?.cols]})); }); terminal.current.onResize(({cols, rows})=>{