Closed ZombieChibiXD closed 3 years ago
I have the same problem, I can not understand how to set up the work of alias for Express files
Hi, at the moment aliases are not supported in server middleware, you have to use relative path.
import moduleAlias from "module-alias";
moduleAlias.addAliases({
"@": path.join(__dirname, "/../"),
});
@ZombieChibiXD This is how I solved it inside serverMiddleware folder
In nuxt .vue files, I can just use '@/path/to/component', but for some reason the same thing don't work on the express.js files..