I'm experiencing an issue in my app where routes work fine when I use router.map({}) with the vue-router, but they fail to work when I pass them directly in the constructor. Any insight into why this might be happening?
// Routes that work:
const router = new VueRouter()
router.map({
'/user' : {
component : User,
subRoutes : {}
}
})
// Routes that do not work:
const router = new VueRouter({
routes : [
{
path : '/user',
component : User,
children : []
}
]
})