RE: API design principles - HTMLXML literals

On 9 Okt 2015 at 16:49, Dave Longley wrote:
> On 10/09/2015 07:20 AM, John Walker wrote:
>> In our case these literals could be quite large and contain extensive
>> markup.

Does extensive also mean complex?

[...]

> Due to the nature of HTML, how particular elements are rendered is
> largely dependent on the context of the document and a number of other
> independent style inputs. By directly embedding it in your data, your
> data is no longer consumable by any client, but rather, a client must
> adhere to your overall presentation style to do anything with the data.
> Either don't make that part of your data linked or present the data in a
> way that other clients could at least reasonably do something with it.

This would be my main concern as well. It's quite common these days to work around those issues by using a less powerful markup language (in most cases Markdown). I don't have enough information of the constraints of your system but I think I would try to give clients more information... unless it is really just a reference to an HTML file. In that case a simple property that tells a client something along the lines of "here's a link to the documentation" would be sufficient I guess.


--
Markus Lanthaler
@markuslanthaler

Received on Friday, 9 October 2015 18:21:56 UTC