P
P
Pavel Zhukau2015-09-05 12:13:07
JavaScript
Pavel Zhukau, 2015-09-05 12:13:07

How do Backend and Frontend interact?

Hello. An interesting question has arisen. I have always written php applications with mvc framework, and rendered html page with the same framework. And now I thought about it and realized that this is not cool, and I want to separate the backend and frontend. By backend I mean the same Laravel, and by frontend I mean Angular. But I have a feeling that I do not correctly understand the very essence of the interaction. As I understand it: there is an api on Laravel, and Angular sends a request through the $http directive, receives a response and displays it on the page, or processes it, as you like. Is it all so? And is the game worth the candle at all? It just seems to me that it will be initially correct architecture, insanely beautiful api, self-satisfaction, happiness, joy and the ability to expand to mobile applications, etc.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
DVamp1r3, 2015-09-05
@NikesDark

As a rule, if people follow a certain architecture/paradigm/principles just for the sake of some kind of "pretty", then they will soon sort out a bunch of problems. Think about whether the development will be faster / better, justify such an approach economically. And if everything fits, then it makes sense.
The code should be readable and scalable, everything else, as a rule, is already personal Wishlist of programmers, not supported by anything.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question