import { createRouter, createWebHashHistory } from "vue-router";
const login = () => import("../views/LoginView.vue");
const routes = [
{ path: "/", redirect: "/login" },
{
path: "/login",
name: "login",
component: login
}
]
/* 使用createRouter创建一个路由对象 */
export const router = createRouter({
/* 使用哈希模式 */
history: createWebHashHistory(),
routes: routes
})