fix: home md not shown
This commit is contained in:
@@ -13,7 +13,6 @@ import {useHomeMarkdown} from "./utils/markdown-queries";
|
||||
|
||||
const App = () => {
|
||||
|
||||
const {home, isLoading, error} = useHomeMarkdown();
|
||||
return (
|
||||
<Router>
|
||||
<div className="app-container">
|
||||
@@ -24,12 +23,9 @@ const App = () => {
|
||||
<Routes>
|
||||
<Route
|
||||
path="/"
|
||||
element={
|
||||
(home && home.id)
|
||||
? <Navigate to = {`/markdown/${home.id}`}/>
|
||||
: <p>HOME</p>
|
||||
}
|
||||
element={<Navigate to = "/markdown/1"/>}
|
||||
/>
|
||||
<Route path="/testx" element={<h2>test2</h2>}/>
|
||||
<Route path="/markdown/:id" element={<MarkdownContent />} />
|
||||
<Route path="/callback" element={<Callback />} />
|
||||
<Route path="/test" element={<h1>TEST</h1>}></Route>
|
||||
|
||||
Reference in New Issue
Block a user