[fetch] Automatically set request's "Content-Type" to "application/json" for POJOs (#47)

As I read the [Body Mixins](https://fetch.spec.whatwg.org/#body-mixin) section, `options.body` can be introspected for certain types, which will cause the `Content-Type` header to be set appropriately.

Can we have it check for plain-ol'-JS-objects (or any other stringifyable type), run `JSON.stringify(options.body`), and set `options.headers["Content-Type"] = "application/json"`?

---
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/issues/47

Received on Wednesday, 6 May 2015 01:07:26 UTC