aboutsummaryrefslogtreecommitdiff
path: root/Timeline/ClientApp/src/app/App.tsx
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2020-06-12 15:42:08 +0800
committercrupest <crupest@outlook.com>2020-06-12 15:42:08 +0800
commit45993fadcc7a4e40acfb75bd0baa19c1354395da (patch)
tree08e716275442f530382735480159926dd51c7fcc /Timeline/ClientApp/src/app/App.tsx
parent1f6c3002791a0d4399171e87f3eeb9df0cce930a (diff)
downloadtimeline-45993fadcc7a4e40acfb75bd0baa19c1354395da.tar.gz
timeline-45993fadcc7a4e40acfb75bd0baa19c1354395da.tar.bz2
timeline-45993fadcc7a4e40acfb75bd0baa19c1354395da.zip
feat(front): 2 enhance on app upgrade.
1. Other pages show alert to refresh when a page confirm upgrade. 2. Upgrade success alert.
Diffstat (limited to 'Timeline/ClientApp/src/app/App.tsx')
-rw-r--r--Timeline/ClientApp/src/app/App.tsx10
1 files changed, 5 insertions, 5 deletions
diff --git a/Timeline/ClientApp/src/app/App.tsx b/Timeline/ClientApp/src/app/App.tsx
index befa2a9c..83ea4ea5 100644
--- a/Timeline/ClientApp/src/app/App.tsx
+++ b/Timeline/ClientApp/src/app/App.tsx
@@ -40,7 +40,7 @@ const App: React.FC = () => {
body = <LoadingPage />;
} else {
body = (
- <React.Suspense fallback={<LoadingPage />}>
+ <Router>
<Switch>
<Route exact path="/">
<Home />
@@ -69,15 +69,15 @@ const App: React.FC = () => {
<NoMatch />
</Route>
</Switch>
- </React.Suspense>
+ </Router>
);
}
return (
- <>
- <Router>{body}</Router>
+ <React.Suspense fallback={<LoadingPage />}>
+ {body}
<AlertHost />
- </>
+ </React.Suspense>
);
};