From e64eaec4131f5e63e63c59b721db7b2a0ba1de3d Mon Sep 17 00:00:00 2001 From: Markus Tacker Date: Mon, 6 Sep 2021 00:44:39 +0200 Subject: [PATCH] fix: re-add ApolloProvider --- frontend/src/AppRoot.tsx | 122 ++++++++++++++++++++------------------- 1 file changed, 63 insertions(+), 59 deletions(-) diff --git a/frontend/src/AppRoot.tsx b/frontend/src/AppRoot.tsx index e885d6ef8..4f26f0832 100644 --- a/frontend/src/AppRoot.tsx +++ b/frontend/src/AppRoot.tsx @@ -1,4 +1,6 @@ +import { ApolloProvider } from '@apollo/client' import { BrowserRouter as Router, Route, Switch } from 'react-router-dom' +import { apolloClient } from './apolloClient' import PrivateRoute from './components/PrivateRoute' import { UserProfileProvider } from './components/UserProfileContext' import { AuthProvider, useAuth } from './hooks/useAuth' @@ -28,67 +30,69 @@ const App = () => { const { isLoading, isAuthenticated } = useAuth() return ( - - - - {isDev && ( - - + + + + + {isDev && ( + + + + )} + {isLoading && ( + + + + )} + + {isAuthenticated ? : } - )} - {isLoading && ( - - + + - )} - - {isAuthenticated ? : } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ) }