mirror of https://gitee.com/answerdev/answer.git
fix(router): Set the correct loader return value for the new version of the router component
This commit is contained in:
parent
8df84b7684
commit
e899f4b362
|
@ -24,7 +24,10 @@ const routes: RouteNode[] = [
|
|||
{
|
||||
path: '/',
|
||||
page: 'pages/Layout',
|
||||
loader: guard.setupApp,
|
||||
loader: async () => {
|
||||
await guard.setupApp();
|
||||
return null;
|
||||
},
|
||||
guard: () => {
|
||||
const gr = guard.shouldLoginRequired();
|
||||
if (!gr.ok) {
|
||||
|
|
Loading…
Reference in New Issue