const routes = [
  {
    path: '/',
    component: () => import('layouts/MainLayout.vue'),
    children: [
      { path: '', component: () => import('pages/IndexPage.vue') },
      // 首页子页面
      { path: 'test', component: () => import('pages/index/ProductList.vue') },
      { path: 'charge', component: () => import('pages/index/charge.vue') },
      { path: 'coin', component: () => import('pages/index/coin.vue') },
      { path: 'prop', component: () => import('pages/index/prop.vue') },
      { path: 'cdk', component: () => import('pages/index/cdk.vue') },
      { path: 'gift', component: () => import('pages/index/gift.vue') },
      { path: 'payment', component: () => import('pages/index/payment.vue') },
      // 用户认证
      { path: 'auth/login', component: () => import('pages/auth/login.vue') },
      { path: 'auth/register', component: () => import('pages/auth/register.vue') },
      { path: 'auth/forget', component: () => import('pages/auth/forget.vue') },
      { path: 'auth/reset', component: () => import('pages/auth/reset.vue') },
      // 消息中心
      { path: 'msg/index', component: () => import('pages/msg/index.vue') },
      // 用户中心
      { path: 'account/index', component: () => import('pages/account/index.vue') },
      { path: 'account/wallet', component: () => import('pages/account/wallet.vue') },
      { path: 'account/profile', component: () => import('pages/account/profile.vue') },
      { path: 'account/coupon', component: () => import('pages/account/coupon.vue') },
      { path: 'account/buy', component: () => import('pages/account/buy.vue') },
      { path: 'account/support', component: () => import('pages/account/support.vue') },
      { path: 'account/invite', component: () => import('pages/account/invite.vue') },
      // 购物车
      { path: 'cart/index', component: () => import('pages/cart/index.vue') },
      // 帮助中心
      { path: 'faq/index', component: () => import('pages/faq/index.vue') },
      // 游戏介绍
      { path: 'game/index', component: () => import('pages/game/index.vue') },
      // 滚动组件演示
      { path: 'scroll-demo', component: () => import('pages/ScrollDemo.vue') }
    ]
  },

  // Always leave this as last one,
  // but you can also remove it
  {
    path: '/:catchAll(.*)*',
    component: () => import('pages/ErrorNotFound.vue')
  }
]

export default routes
