Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions frontend/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion frontend/src/component/Main.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import Home from './Home';
import Add from './link/Add';
import MainLink from './link/Main';
import Navbar from './utils/Navbar';

import NotFound from './utils/NotFound';

export default function Main() {
const isAuthenticated = useSelector(state => state.userState.isAuthenticated)
Expand All @@ -33,6 +33,8 @@ export default function Main() {
<Route exact path="/add" component={Add} />

<Route exact path="/link/:email" component={MainLink} />

<Route component={NotFound}/>
</Switch>
</div>
</Router>
Expand Down
22 changes: 22 additions & 0 deletions frontend/src/component/utils/NotFound.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import React from "react";
import { Link } from "react-router-dom";
import { Button } from "@material-ui/core";

const NotFound = () => {
return (
<div className='background-grad w-100 overflow-hidden' style={{ height: 'calc(100vh - 64px)' }}>
<div className="container mt-3">
<div className="row">
<di className='col-md-6'>
<h1>404.</h1>
<h3>This page does not exists</h3>
<p>Looks like you're lost! please go to the homepage.</p>
<Link to='/'><Button>Home</Button></Link>
</di>
</div>
</div>
</div>
)
}

export default NotFound
6 changes: 6 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.