From 195d9431c408e35d1645724f2ae0f354d0ad0af6 Mon Sep 17 00:00:00 2001 From: Rishi Ghan Date: Mon, 1 Nov 2021 01:10:29 -0700 Subject: [PATCH] =?UTF-8?q?=E2=9C=8F=EF=B8=8FEditing=20socket=20client=20c?= =?UTF-8?q?onfig?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/client/store/index.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/client/store/index.ts b/src/client/store/index.ts index e285a16..a1433f6 100644 --- a/src/client/store/index.ts +++ b/src/client/store/index.ts @@ -3,17 +3,22 @@ import { createStore, applyMiddleware, compose } from "redux"; import { createBrowserHistory } from "history"; import thunk from "redux-thunk"; import createRootReducer from "../reducers"; -import socketIO from "socket.io-client"; +import { io } from "socket.io-client"; import socketIoMiddleware from "redux-socket.io-middleware"; // import { SOCKET_BASE_URI } from "../constants/endpoints"; -const io = socketIO(`http://rook:3001`); +// const socketConnection = io(`http://rook:3001`); + export const history = createBrowserHistory(); const configureStore = (initialState) => { const store = createStore( createRootReducer(history), initialState, compose( - applyMiddleware(socketIoMiddleware(io), thunk, routerMiddleware(history)), + applyMiddleware( + // socketIoMiddleware(socketConnection), + thunk, + routerMiddleware(history), + ), // window.__REDUX_DEVTOOLS_EXTENSION__ && window.__REDUX_DEVTOOLS_EXTENSION__(), ), );