import { createWebHistory, createWebHashHistory,createRouter } from 'vue-router'

export const constantRoutes = [

  {
    path: '',
    component: () => import('./components/index'),
    hidden: true
  },
]


const router = createRouter({
  history: createWebHashHistory(import.meta.env.VITE_APP_CONTEXT_PATH),
  routes: constantRoutes,
  scrollBehavior(to, from, savedPosition) {
    if (savedPosition) {
      return savedPosition
    } else {
      return { top: 0 }
    }
  },
});

export default router;
