Json, or html which is better?

How to get data from the server with ajax json or html , I'm interested in the pros and cons and not the process.
June 3rd 19 at 19:17
1 answer
June 3rd 19 at 19:19
JSON is universal, no privacy templates to make the server smaller in size
Ie json weigh less or something ?About the templates not understand - Flavie commented on June 3rd 19 at 19:22
in json you get just the data, and on the client side create the necessary html.
Ie the same json you can use in different places.
And Yes, if there is no pile of tags is smaller.

json is more complicated but more flexible
html code on 2 lines but no flexibility. - Viva_Goldner commented on June 3rd 19 at 19:25
realized thanks to Ah Wai the big - Flavie commented on June 3rd 19 at 19:28

Find more questions by tags Web Development