2022-05-30 21:38:45 +02:00
|
|
|
import React from 'react'
|
|
|
|
import { QueryClient, QueryClientProvider } from 'react-query'
|
|
|
|
import { Route, Routes } from 'react-router-dom'
|
|
|
|
import './App.css'
|
2022-06-04 21:03:40 +02:00
|
|
|
import AddStudent from './views/coordinator/AddStudent'
|
2022-05-30 21:38:45 +02:00
|
|
|
import Coordinator from './views/coordinator/Coordinator'
|
|
|
|
import Groups from './views/coordinator/Groups'
|
|
|
|
import Leaders from './views/coordinator/Leaders'
|
|
|
|
import Students from './views/coordinator/Students'
|
2022-05-22 21:28:25 +02:00
|
|
|
|
2022-05-30 21:38:45 +02:00
|
|
|
const queryClient = new QueryClient({
|
|
|
|
defaultOptions: {
|
|
|
|
queries: {
|
|
|
|
refetchOnWindowFocus: false,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
})
|
2022-05-16 23:17:36 +02:00
|
|
|
|
|
|
|
function App() {
|
|
|
|
return (
|
2022-05-22 21:28:25 +02:00
|
|
|
<div>
|
|
|
|
<QueryClientProvider client={queryClient}>
|
|
|
|
<Routes>
|
|
|
|
<Route index element={<Coordinator />} />
|
|
|
|
<Route path="coordinator" element={<Coordinator />}>
|
|
|
|
<Route path="groups" element={<Groups />} />
|
|
|
|
<Route path="students" element={<Students />} />
|
|
|
|
<Route path="leaders" element={<Leaders />} />
|
2022-06-04 21:03:40 +02:00
|
|
|
<Route path="add-student" element={<AddStudent />} />
|
2022-05-22 21:28:25 +02:00
|
|
|
</Route>
|
|
|
|
</Routes>
|
|
|
|
</QueryClientProvider>
|
2022-05-16 23:17:36 +02:00
|
|
|
</div>
|
2022-05-30 21:38:45 +02:00
|
|
|
)
|
2022-05-16 23:17:36 +02:00
|
|
|
}
|
|
|
|
|
2022-05-30 21:38:45 +02:00
|
|
|
export default App
|