Use of routes at the frontend or backend

Asked

Viewed 361 times

3

In relation to routing, it is more appropriate for routing to be on front and the same make requests to the server through AJAX, or the routing stay in the back and render the same views of front?

  • What would this routing be?

1 answer

2


False dichotomy, because routing in one or the other exists to route what is in that layer, the fact that it has used in one layer does not make it unnecessary to use in another, of course, as long as you are using architectures that require routing. In other words, use or not, it has nothing to do with what you’re worried about in the question and yes it makes sense in the architecture used in that layer.

You can use a routing in one of them and not use in another simply because the architecture of that layer has been designed in a way that doesn’t need routing.

In general, routing is necessary for complex architectures, and there was a time when people only adopted complex solutions to complex problems (some people still do, thankfully), but today it’s common for people to adopt complex architectures because it’s fashionable, the person adopts without even understanding why is doing that and what benefit will have with the adoption of that.

I see people avoiding routing with React on frontend (or so it was).

Browser other questions tagged

You are not signed in. Login or sign up in order to post.