mirror of
https://github.com/SomboChea/ui
synced 2026-01-19 01:25:51 +07:00
fix: @typescript-eslint/explicit-function-return-type
This commit is contained in:
@@ -12,15 +12,15 @@ export const NOT_FOUND_TEXT = "Sorry, we couldn't find it...";
|
||||
export type NotFoundProps = RouteComponentProps & { width: any; history: any };
|
||||
|
||||
const NotFound: React.FC<NotFoundProps> = ({ history, width }) => {
|
||||
const handleGoTo = (to: string) => () => {
|
||||
const handleGoTo = (to: string): (() => void | undefined) => () => {
|
||||
history.push(to);
|
||||
};
|
||||
|
||||
const handleGoBack = () => () => {
|
||||
const handleGoBack = (): ((e: React.MouseEvent<HTMLElement, MouseEvent>) => void | undefined) => () => {
|
||||
history.goBack();
|
||||
};
|
||||
|
||||
const renderList = () => (
|
||||
const renderList = (): JSX.Element => (
|
||||
<List>
|
||||
<ListItem button={true} divider={true} onClick={handleGoTo('/')}>
|
||||
{'Home'}
|
||||
@@ -31,7 +31,7 @@ const NotFound: React.FC<NotFoundProps> = ({ history, width }) => {
|
||||
</List>
|
||||
);
|
||||
|
||||
const renderSubTitle = () => (
|
||||
const renderSubTitle = (): JSX.Element => (
|
||||
<Typography variant="subtitle1">
|
||||
<div>{"The page you're looking for doesn't exist."}</div>
|
||||
<div>{'Perhaps these links will help find what you are looking for:'}</div>
|
||||
|
||||
Reference in New Issue
Block a user