I'm trying to find a solution for my server and for its structure. What I want to do is separate.
app.post("/login", function(request, response) {
});
app.post("/register", function(request, response) {
});
app.get("/", function(request, response) {
});
into different files. In my case, they are all standing in a file called "server.js". How can I separate them to work on them better?, and run all of them at the same time. I searched out this situation and I found different types of this case. But couldn't get a clear answer.