1
0
Fork 0
blog/src/pages/404.tsx

29 lines
819 B
TypeScript
Raw Normal View History

2020-05-22 14:38:19 +02:00
import React, { ReactElement } from 'react'
2021-03-01 00:36:51 +01:00
import { Link, PageProps } from 'gatsby'
2023-01-29 22:58:19 +01:00
import HeadMeta, { HeadMetaProps } from '../components/atoms/HeadMeta'
2020-03-04 22:21:12 +01:00
import Page from '../components/templates/Page'
import * as styles from './404.module.css'
2018-07-17 23:33:55 +02:00
2022-11-19 16:09:13 +01:00
const meta: Partial<HeadMetaProps> = {
title: `I'm sorry Dave`,
description: `I'm afraid I can't do that`
2018-11-07 01:15:41 +01:00
}
2022-11-19 16:09:13 +01:00
const NotFound = (): ReactElement => (
<Page title={meta.title}>
<div className={styles.hal9000} />
2018-07-17 23:33:55 +02:00
<div className={styles.wrapper}>
2022-11-19 16:09:13 +01:00
<h1 className={styles.title}>{meta.title}</h1>{' '}
<p className={styles.text}>{meta.description}</p>
2018-09-09 18:16:13 +02:00
<Link to={'/'}>Back to homepage</Link>
</div>
2018-09-16 15:08:52 +02:00
</Page>
2018-07-17 23:33:55 +02:00
)
export default NotFound
2022-11-19 16:09:13 +01:00
export function Head(props: PageProps) {
return <HeadMeta {...meta} slug={props.location.pathname} />
}