microformats2-mime-type

From Microformats Wiki
Revision as of 20:16, 13 April 2015 by TomMorris (talk | contribs) (new page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

This page is for discussing the potential benefits and disadvantages of registering a MIME type for microformats2.

Potential MIME types

Note: None of these are officially registered MIME types. Until the IETF registers the MIME type, it is not official.

  • application/microformats+json
  • application/microformats2+json
  • application/mf2+json
  • application/uf2+json


Advantages

  • if a user is using content negotiation, one URL can have both a microformats2 JSON representation (which is simply the parsed content of what the text/html or application/xhtml+xml view contains) and a site or domain specific JSON representation of their own (commonly used for APIs)
  • it provides a naming structure for other future formats that have (close to) bidirectional conversion support with the semantics of JSON (e.g. YAML, BSON, Apache Avro, Thrift) - we cannot assume that JSON will be around forever or that it will suit all use cases even if it seems like it currently is the best choice

Disadvantages

  • some HTTP libraries (e.g. Python's requests library) will use application/json to auto-parse JSON, but the routine that auto-parses JSON will not be activated on custom MIME types

Discussion

See also