Commit f83de343 by Moorthy G

feat(404): handle 404 response

parent 938cacf0
......@@ -6,10 +6,7 @@ export default function PageNotFound() {
return (
<div className={styles.notFound}>
<img src={require('./img/404.png')} alt="" />
<p>The page you're looking for is not found</p>
<Button href="/" onClick={() => sendGA('page-not-found', 'cta')}>
Back to home
</Button>
<Button href="/">Back to Home</Button>
</div>
);
}
import PageNotFound from '@components/page-not-found';
function FourOhFour() {
return <PageNotFound />;
}
export default FourOhFour;
import PageNotFound from '@components/page-not-found';
import '@styles/global.scss';
function MyApp({ Component, pageProps }) {
return pageProps.statusCode === 404 ? (
<PageNotFound />
) : (
<Component {...pageProps} />
);
return <Component {...pageProps} />;
}
export default MyApp;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment