To update the router manager, follow these instructions:
- Open the index.js file in the src/router folder.
- In each route that has a component property, we will transform the direct attribution of the component to a new function. This will be an arrow function returning the import() method of webpack:
{
path: '/login',
name: 'login',
component: () => import('@/views/Login'),
meta: {
authenticated: false,
},
},
-
Repeat the process on each one of the route objects that has a component property.