umi max自定义布局

 

 

import { defineConfig } from '@umijs/max';

export default defineConfig({
  antd: {
  },
  access: {},
  model: {},
  initialState: {},
  request: {},
  layout: false,
  // layout: {
  //   title: '@umijs/max',
  // },
  routes: [
    {
      path: '/',
      component: '../layouts/BaseLayout',
      layout: false,
      routes:[
        {
          path: '/',
          redirect: '/home',
        },
        {
          name: '首页',
          path: '/home',
          // layout: false,
          component: './Home',
        },
        {
          name: '权限演示',
          path: '/access',
          component: './Access',
        },
        {
            name: ' CRUD 示例',
            path: '/table',
            component: './Table',
        },
        {
            name: ' doc 示例',
            path: '/docs',
            component: './docs',
        }
      ]
    }
  ],
  npmClient: 'pnpm',
});

 

posted @ 2022-08-08 17:47  zyip  阅读(3686)  评论(0)    收藏  举报