With my router.js file currently reaching around 500 lines, I’m looking for a better way to structure it.
{
path: "/",
component: () => import("./../src/views/dashboard/Dashboard.vue"),
meta: {
auth: true,
title: "Dashboard"
}
},
{
path: "/regionWiseDashboard",
component: () => import("./../src/views/dashboard/RegionWiseDashboard.vue"),
meta: {
auth: true,
title: "Dashboard"
}
},
Every time I add a new component, the code repeats itself which is becoming quite overwhelming. Is there a more efficient way to organize this? Perhaps storing all components in a JSON or breaking down the main js file into smaller ones?