Re:Unwalled.Garden: souped-up RSS for P2P social apps
by dpe82 on Thursday June 06, 2019 @04:25PM
(#20118744)
How do you express
"Why didn't you use <img src="xml_has_its_uses.png"> XML!?"
with json?
Re:Unwalled.Garden: souped-up RSS for P2P social apps
by rolltiide on Thursday June 06, 2019 @04:31PM
(#20118826)
you don't, you just store the string as is in the body tag and let the client side parser know how to parse html strings that may also include an image tag
what is the argument here? why didn't you know you answered your own question
"body":"Why didn't you use <img src="xml_has_its_uses.png"> XML!?"
Re:Unwalled.Garden: souped-up RSS for P2P social apps
by grenoire on Thursday June 06, 2019 @05:35PM
(#20119489)
OP is asking what the content type of the body is to be interpreted as.
You're assuming HTML string, which might not always be correct. What do you do with Markdown?
You need to have a standard way to represent things like this, because otherwise it won't gain traction solely due to the immense complexity of implementing viewers.
Edit: On top of this, HTML might not necessarily be the best choice. In that case it'd just be browser wrappers galore.
Re:Unwalled.Garden: souped-up RSS for P2P social apps
by elcomet on Friday June 07, 2019 @03:06AM
(#20122293)
Well grandparent also assumed HTML since he put an HTML tag with html attributes in his node. I'm not sure how different this is, and if he wants to convert this to markdown he'll also need a html to markdown converter.
Re:Unwalled.Garden: souped-up RSS for P2P social apps
by rolltiide on Friday June 07, 2019 @10:19AM
(#20124738)
gain traction? you are really talking about a non-issue this decade
everyone is already used to making their frontend, backend and database parse and store external things in key value pairs
this schema pre-detecting ship has sailed a long time ago
Re:Unwalled.Garden: souped-up RSS for P2P social apps
by jazzyjackson on Thursday June 06, 2019 @09:51PM
(#20120972)
Assuming It's eventually going to be read as HTML I do this
{"body":{
"childNodes": [
{"span":{"textContent":"Why didn't you use "}},
{"img":{"src":"xml_has_its_uses.png"}},
{"span":{"textContent":" XML!?"}}
]
}}
How is that different from XML if your body is defined as a text field?