Django separated front and rear ends are not separated understood

Not separated front and rear ends

	在前后端不分离的应用模式中,前端页面看到的效果都是由后端控制,由后端渲染页面或重定向,
也就是后端需要控制前端的展示,前端与后端的耦合度很高。
    这种应用模式比较适合纯网页应用,但是当后端对接App时,App可能并不需要后端返回一个HTML网页,
而仅仅是数据本身,所以后端原本返回网页的接口不再适用于前端App应用,为了对接App后端还需再开发一套接口。

Data exchange requests as shown below:
Here Insert Picture Description

In simple terms: the front and rear end points separated the system, there is no front-end, the browser can see the page is provided by the back-end and back-end service only, no front-end services

Separate front and rear ends

	在前后端分离的应用模式中,后端仅返回前端所需的数据,不再渲染HTML页面,不再控制前端的效果。
至于前端用户看到什么效果,从后端请求的数据如何加载到前端中,都由前端自己决定,网页有网页的处理方式,
App有App的处理方式,但无论哪种前端,所需的数据基本相同,后端仅需开发一套逻辑对外提供数据即可。

	在前后端分离的应用模式中 ,前端与后端的耦合度相对较低。在前后端分离的应用模式中,
我们通常将后端开发的每个视图都称为一个接口,或者API,前端通过访问接口来对数据进行增删改查。

FIG interaction data corresponding to the following:

Here Insert Picture Description

In simple terms: the separation of the front and rear end systems, front end, the browser can see the page is to provide front-end services, back-end development web interface provides data to the front end, the front end after to deal with again demonstrated to the browser.

Published 82 original articles · won praise 43 · views 180 000 +

Guess you like

Origin blog.csdn.net/liudinglong1989/article/details/104321325