Browse Source

fix menu bug

pull/3537/head
愚道 7 years ago
committed by Yu
parent
commit
7954726c0c
  1. 14
      config/config.js
  2. 3
      src/pages/BasicDemo.js
  3. 11
      src/pages/Welcome.js

14
config/config.js

@ -50,12 +50,18 @@ export default {
path: '/',
component: '../layouts/BasicLayout',
routes: [
{ path: '/', redirect: '/welcome' },
// dashboard
{
path: '/',
name: 'dashboard',
icon: 'dashboard',
component: './BasicDemo',
path: '/welcome',
name: 'welcome',
icon: 'smile',
component: './Welcome',
},
{
path: 'https://github.com/umijs/umi-blocks/tree/master/ant-design-pro',
name: '更多页面',
icon: 'block',
},
],
},

3
src/pages/BasicDemo.js

@ -1,3 +0,0 @@
import React from 'react';
export default () => <p>hello pro!</p>;

11
src/pages/Welcome.js

@ -0,0 +1,11 @@
import React from 'react';
export default () => (
<p>
想要添加更多页面请参考{' '}
<a href="https://umijs.org/guide/block.html" target="_blank" rel="noopener noreferrer">
umi 区块
</a>
</p>
);
Loading…
Cancel
Save