]> Untitled Git - lemmy-ui.git/blob - src/shared/components/no-match.tsx
Change from using Link to NavLink. resolve #269
[lemmy-ui.git] / src / shared / components / no-match.tsx
1 import { I18nKeys } from "i18next";
2 import { Component } from "inferno";
3 import { i18n } from "../i18next";
4
5 export class NoMatch extends Component<any, any> {
6   private errCode = new URLSearchParams(this.props.location.search).get(
7     "err"
8   ) as I18nKeys;
9
10   constructor(props: any, context: any) {
11     super(props, context);
12   }
13
14   render() {
15     return (
16       <div class="container">
17         <h1>404</h1>
18         {this.errCode && (
19           <h3>
20             {i18n.t("code")}: {i18n.t(this.errCode)}
21           </h3>
22         )}
23       </div>
24     );
25   }
26 }