Answer the question
In order to leave comments, you need to log in
What is the best approach to backend design? What is the fundamental difference between the approaches?
For example, a controller in Node.js can be written like this:
export class UserController {
static async login(req, res) {
try {} catch(e) {}
}
}
const login = async (req, res) => {
try {} catch(e) {}
}
const controller = { login }
export default controller
Answer the question
In order to leave comments, you need to log in
Is there a fundamental difference between these approaches?
which approach is better to use. While there is a feeling that all this is purely a matter of taste.
And what other approaches are there?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question