Skip to content

Commit

Permalink
Merge pull request #25 from JumboCode/myi/vercel-routes
Browse files Browse the repository at this point in the history
add vercel.json for routes
  • Loading branch information
myix765 authored Nov 2, 2024
2 parents 538fc05 + d5761be commit b640d6a
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 12 deletions.
12 changes: 6 additions & 6 deletions src/components/NavBar/NavBar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ const NavBar = () => {

{/* Desktop navigation */}
<div className="hidden sm:flex sm:items-center sm:space-x-4">
<NavLink href="/About" isMobile={false}>About</NavLink>
<NavLink href="/Contact" isMobile={false}>Contact</NavLink>
<NavLink href="/SignUp" isMobile={false}>Sign Up</NavLink>
<NavLink href="/about" isMobile={false}>About</NavLink>
<NavLink href="/contact" isMobile={false}>Contact</NavLink>
<NavLink href="/signup" isMobile={false}>Sign Up</NavLink>
{/* <LanguageSelector /> */}
</div>

Expand All @@ -40,9 +40,9 @@ const NavBar = () => {
{/* Mobile menu */}
<div className={`sm:hidden ${isMenuOpen ? 'block' : 'hidden'}`}>
<div className="pt-2 pb-3 space-y-1">
<NavLink href="/About" isMobile={true}>About</NavLink>
<NavLink href="/Contact" isMobile={true}>Contact</NavLink>
<NavLink href="/SignUp" isMobile={true}>Sign Up</NavLink>
<NavLink href="/about" isMobile={true}>About</NavLink>
<NavLink href="/contact" isMobile={true}>Contact</NavLink>
<NavLink href="/signup" isMobile={true}>Sign Up</NavLink>
</div>
<div className="pt-4 pb-3 border-t border-gray-200">
{/* <LanguageSelector mobile /> */}
Expand Down
8 changes: 4 additions & 4 deletions src/components/PageRoutes.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ export default function PageRoutes() {
return (
<div>
<Route path="/" component={Home} />
<Route path="/About" component={About} />
<Route path="/Contact" component={Contact} />
<Route path="/SignUp" component={SignUp} />
<Route path="/Login" component={Login} />
<Route path="/about" component={About} />
<Route path="/contact" component={Contact} />
<Route path="/signup" component={SignUp} />
<Route path="/login" component={Login} />
</div>
);
};
2 changes: 1 addition & 1 deletion src/pages/Login.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export default function Login() {
<div className="bg-white w-2/3 md:1/2 lg:w-2/5 py-16 px-5 sm:px-20 rounded-lg shadow-2xl min-h-min">
<h1 className="text-2xl sm:text-3xl mb-3">Login</h1>
<h3 className="text-sm sm:text-base text-slate-400 mb-6">Don't have an account?
<Link href="/SignUp" className="text-blue-400"> Sign up</Link>
<Link href="/signup" className="text-blue-400"> Sign up</Link>
</h3>

<form method="POST" onSubmit={handleSubmit}>
Expand Down
2 changes: 1 addition & 1 deletion src/pages/SignUp.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export default function SignUp() {
<div>
<h3 className="text-3xl ml-10"> Sign up </h3>
<p className="mt-8 text-gray-500 ml-10"> Already have an account?
<Link className="ml-1 font-bold text-blue-400" href="/Login"> Log In</Link>
<Link className="ml-1 font-bold text-blue-400" href="/login"> Log In</Link>
</p>
</div>

Expand Down
8 changes: 8 additions & 0 deletions vercel.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"rewrites": [
{
"source": "/((?!api/)[^./]+)",
"destination": "/"
}
]
}

0 comments on commit b640d6a

Please sign in to comment.