From 7483c85518188126f86cbeecc37f96761ad4b09b Mon Sep 17 00:00:00 2001 From: rektdeckard Date: Mon, 14 Sep 2020 17:45:01 -0400 Subject: [PATCH] App: add ErrorBoundary around IconGrid The IconGrid can now fallback to an ErrorBoundary, which renders a generic Warn component with a "Search error" message. --- src/components/App/App.tsx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/components/App/App.tsx b/src/components/App/App.tsx index 7703aaf..507cd7d 100644 --- a/src/components/App/App.tsx +++ b/src/components/App/App.tsx @@ -5,6 +5,8 @@ import Header from "../Header/Header"; import Toolbar from "../Toolbar/Toolbar"; import IconGrid from "../IconGrid/IconGrid"; import Footer from "../Footer/Footer"; +import ErrorBoundary from "../ErrorBoundary/ErrorBoundary"; +import Warn from "../Warn/Warn"; const App: React.FC = () => { return ( @@ -12,9 +14,11 @@ const App: React.FC = () => {
- Loading...}> - - + }> + Loading...}> + + +