From 4abec204a839dd078ea77a34bfcae580beafaef6 Mon Sep 17 00:00:00 2001 From: OJ Abba Date: Tue, 1 Jul 2025 15:39:13 +0100 Subject: [PATCH] =?UTF-8?q?[Chore]=20Introduce=20errors=20=F0=9F=92=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- manifest.json | 2 +- src/pages/LoadingAppPage/LoadingAppPage.tsx | 33 +++++++++++++++++++-- 2 files changed, 31 insertions(+), 4 deletions(-) diff --git a/manifest.json b/manifest.json index a5b35ba..b624234 100644 --- a/manifest.json +++ b/manifest.json @@ -43,7 +43,7 @@ "default": "", "type": "app_embedded", "options": { "entrypoint": "#/admin/global-sign-in" }, - "isRequired": true, + "isRequired": false, "isBackendOnly": true, "order": 30 } diff --git a/src/pages/LoadingAppPage/LoadingAppPage.tsx b/src/pages/LoadingAppPage/LoadingAppPage.tsx index b7e0b4a..4b8528f 100644 --- a/src/pages/LoadingAppPage/LoadingAppPage.tsx +++ b/src/pages/LoadingAppPage/LoadingAppPage.tsx @@ -1,11 +1,38 @@ import { LoadingSpinner } from "@deskpro/app-sdk"; -import { useCheckIsAuth } from "./hooks"; +// import { useCheckIsAuth } from "./hooks"; +import { useState, useEffect } from "react"; +import { Button } from "@deskpro/deskpro-ui"; const LoadingAppPage = () => { - useCheckIsAuth(); + // useCheckIsAuth(); + + const [errorState, setErrorState] = useState(null) + + useEffect(() => { + if (errorState === "left") { + throw new Error("Hello from TeamViewer") + } + + if (errorState === "right") { + throw "HI from TeamViewer" + } + + + + }, [errorState]) return ( - + <> +