Hello everyone i am making a social network and i came to the point where i need multiple users to test my app so i tried hosting it, however heroku does not work as supposed when using require to get my modules.
I use modules for better organisation, here is the code that makes the error:
app.get("/login", require("./routs/loginGet.js")); app.post("/login", require("./routs/loginPost.js")); //app.get("/logout", require("./routs/logout.js")); app.get("/conversation/:chatId", require("./routs/conversationGet")); app.post('/message/:chatId/', requiresLogin, require("./routs/messagePost.js"))
The error says no such module. Please tell me the correct way to organize my code in modules so that heroku accepts it.