Syndication and CSS
This topic seems to have resurfaced now that Joi is putting this in his feeds and there even is a howto... like Shelley and others, I've yet to be convinced that syndicating CSS is appropriate, but on a purely technical level, here's a few comments:
- Richard's howto gives a different recommendation for how to encode this data inside a content:encoded element for RSS 1.0 and RSS 2.0. Given the way that most aggregators deal with versions and RSS, I don't think that this is appropriate. The recommendation given for RSS 1.0 is the correct one. I note that Joi has followed the RSS 1.0 recommendation for both his 1.0 and 2.0 feeds.
- The Atom recommendation is incomplete: whether the data needs to be escaped or not would depend on the value of the mode parameter.
- Aggregators that combine content from multiple feeds into a single page (examples: Radio Userland and Aggie) will find it quite difficult to handle item level CSS properly - and by default, they will do the wrong thing. Note that by default, the Radio Userland aggregator will ignore content:encoded, so this is less of a problem.
- SharpReader displays the link tag that is present in Joi's feed verbatim instead of interpreting it as markup.
- RSSBandit seems to strip this tag entirely.
Overall my recommendation is to not to try to tunnel this information inside the content, but to place it outside the content (either at the item or the feed level). This would make it easier for aggregators to identify that a stylesheet is desired and to take the appropriate action.
In Atom's case, the recommendation would be to simply place the link tag at either the feed or specific entry level.
In RSS, I would also make a similar recommendation, perhaps adopting the xhtml namespace.