4 ms·
Maybe, but not really; seems like this thread is more about intent (“I just want a preview”) while content type is more about representation (“I want the conten
by stingraycharles 6y ago
Maybe, but not really; seems like this thread is more about intent (“I just want a preview”) while content type is more about representation (“I want the content as json”). I can imagine that there will be websites that are actively using the accept parameter to distinguish between “regular visitors” and have their APIs at the same paths (didn’t Reddit do this at some point?), and thus your approach would break in this case.
I guess what this is really about is, I hate to say it, but something in the direction of the semantic web, where web servers (and in this case, CloudFlare et al) actually gain a deeper understanding of the content they serve, and a web browser / crawler being able to query this content directly.
- stickfigure 6y agoAccept: text/preview
- stingraycharles 6y agoIn what content type? Json? Xml? Html?
- fiddlerwoaroof 6y agoIt seems to me that what "previews" really want is an API for the page's content in a structured format: OpenGraph tags and other microformats are one representation, but it's annoying to have to load _all_ the HTML just to grab title and the OG tags.