Skip to content

Commit

Permalink
Hash router (#23)
Browse files Browse the repository at this point in the history
* feat: switch from BrowserRouter to HashRouter

* Fix hashrouter
  • Loading branch information
noworneverev authored Oct 23, 2024
1 parent 22f0720 commit 1006133
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions src/app/layout/App.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useEffect, useState } from "react";
import {
BrowserRouter as Router,
HashRouter as Router,
Routes,
Route,
Navigate,
Expand Down Expand Up @@ -79,7 +79,7 @@ const App: React.FC = () => {

return (
<ThemeProvider theme={theme}>
<Router basename="/graphrag-visualizer">
<Router>
<Container disableGutters maxWidth={false}>
<CssBaseline />

Expand Down Expand Up @@ -120,18 +120,11 @@ const App: React.FC = () => {
)}
</Box>
<Routes>
{" "}
{/* **Added Routes** */}
<Route path="/" element={<Navigate to="/upload" replace />} />{" "}
{/* **Redirect Root to /upload** */}
<Route path="/upload" element={<GraphDataHandler />} />{" "}
{/* **Upload Tab** */}
<Route path="/graph" element={<GraphDataHandler />} />{" "}
{/* **Graph Visualization Tab** */}
<Route path="/data" element={<GraphDataHandler />} />{" "}
{/* **Data Tables Tab** */}
<Route path="*" element={<Navigate to="/upload" replace />} />{" "}
{/* **Catch-All Redirect** */}
</Routes>

{/* <GraphDataHandler /> */}
Expand Down

0 comments on commit 1006133

Please sign in to comment.