[Vuejs]-Vue2.0 Encounter push undefined occurs during router.push

0👍

You are not declaring the router so try this:

   const router = new VueRouter({
        routes = [
            {path: '/', component: Home},
            {path: '/trafficSetting', name:'trafficS', component: trafficSetting},
            {path: '/seedResourcesManagement', component: seedResourcesManagement},
            {path: '/driverUserManagement', component: driverUserManagement},
            {path: '/whiteblackListManagement', component: whiteblackListManagement},
            {path: '/VPNserverManagement', component: VPNserverManagement}
        ]
    })

Leave a comment