From d664ddc9b84b25922239e3bbc253b35ea54f2533 Mon Sep 17 00:00:00 2001 From: Hassan Abouelela <47495861+HassanAbouelela@users.noreply.github.com> Date: Sun, 3 Jan 2021 05:47:07 +0300 Subject: Fixes Preexisting Linting Issues Fixes all errors, and most warnings generated by eslint. Most were fixed by eslint automatically such as indentation and quotes. Signed-off-by: Hassan Abouelela <47495861+HassanAbouelela@users.noreply.github.com> --- src/pages/LandingPage.tsx | 48 +++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 24 deletions(-) (limited to 'src/pages/LandingPage.tsx') diff --git a/src/pages/LandingPage.tsx b/src/pages/LandingPage.tsx index 1320c14..124bbcf 100644 --- a/src/pages/LandingPage.tsx +++ b/src/pages/LandingPage.tsx @@ -9,40 +9,40 @@ import { getForms, Form } from "../api/forms"; import OAuth2Button from "../components/OAuth2Button"; import Loading from "../components/Loading"; -function LandingPage() { - const [forms, setForms] = useState(); - - useEffect(() => { - const fetchForms = async () => { - setForms(await getForms()); +function LandingPage(): JSX.Element { + const [forms, setForms] = useState(); + + useEffect(() => { + const fetchForms = async () => { + setForms(await getForms()); + }; + fetchForms(); + }, []); + + if (!forms) { + return ; } - fetchForms(); - }, []); - - if (!forms) { - return ; - } - return
- -
+ return
+ +
-
-

Available Forms

+

Available Forms

- + - {forms.map(form => ( - - ))} -
-
-
+ {forms.map(form => ( + + ))} +
+
+ ; } export default LandingPage; -- cgit v1.2.3