mirror of
https://github.com/lemeow125/React-NotesApp.git
synced 2024-11-17 06:29:28 +08:00
Move to hash router and change url accordingly
This commit is contained in:
parent
e61aef640b
commit
23a394643d
2 changed files with 7 additions and 3 deletions
|
@ -2,7 +2,7 @@
|
|||
"name": "react-notes",
|
||||
"version": "0.1.0",
|
||||
"private": true,
|
||||
"homepage": "https://lemeow125.github.io/react-notes",
|
||||
"homepage": "https://lemeow125.github.io/react-notes/#",
|
||||
"dependencies": {
|
||||
"@emotion/react": "^11.10.6",
|
||||
"@emotion/styled": "^11.10.6",
|
||||
|
|
|
@ -2,7 +2,11 @@ import React from "react";
|
|||
import ReactDOM from "react-dom/client";
|
||||
import "./index.css";
|
||||
import reportWebVitals from "./reportWebVitals";
|
||||
import { createBrowserRouter, RouterProvider } from "react-router-dom";
|
||||
import {
|
||||
createBrowserRouter,
|
||||
createHashRouter,
|
||||
RouterProvider,
|
||||
} from "react-router-dom";
|
||||
|
||||
import Home from "./Routes/Home/Home";
|
||||
import NewNote from "./Routes/NewNote/NewNote";
|
||||
|
@ -19,7 +23,7 @@ import Store from "./Features/Redux/Store/Store";
|
|||
|
||||
const queryClient = new QueryClient();
|
||||
|
||||
const router = createBrowserRouter([
|
||||
const router = createHashRouter([
|
||||
{
|
||||
path: "/",
|
||||
element: <Home />,
|
||||
|
|
Loading…
Reference in a new issue