Vue.use(Router)

export default new Router({

mode:'history',

routes: [

     { path: '/', component: Login },

     { path: '/login', component: Login },

     { path: '/register',component: Register},

      {path: '/*', component: NotFound},

        ]

})

记得要写上  mode:'history', 原因如下

Logo

前往低代码交流专区

更多推荐