-2
I’m using the express.router
nesting my route into several "router.use()". It is possible to take the final route via console?
ex:
const routes = Router();
const v1Router = Router();
const enggajadoresRouter = Router();
routes.use('/v1', V1Router);
v1Router.use('/usuarios', UsuariosRouter);
UsuarioRouter.post('/', usuariosControllers.create);
in this case my post route will be localhost:3000/v1/users/
I need a medium in which I can get the value: '/v1/users/'