- From: guest271314 <notifications@github.com>
- Date: Sun, 18 Dec 2016 10:49:39 -0800
- To: whatwg/fetch <fetch@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/fetch/issues/439@github.com>
MDN documentation of [Request](https://developer.mozilla.org/en-US/docs/Web/API/Request) states: > Note: The body type only can be a Blob, BufferSource, FormData, URLSearchParams, USVString or ReadableStream type, so for adding a JSON object to the payload it need to be stringify that object. Though at MDN documentation for [`Request()`](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request) `ReadableStream` is not listed as valid option. > body: Any body that you want to add to your request: this can be a Blob, BufferSource, FormData, URLSearchParams, or USVString object. Note that a request using the GET or HEAD method cannot have a body. Could not find an example of the same at the specification. After searching before posting the question here or at stackoverflow, found that the question had already recently been asked [Fetch with ReadableStream](http://stackoverflow.com/questions/40939857/fetch-with-readablestream). Tried a slightly different pattern than the `javascript` at Question at SO, though result was essentially the same. Is this possible? Is MDN documentation incorrect? If possible, what is the correct pattern to achieve the expected result of `fetch()` reading from `ReadableStream` to populate the `body` of a `POST` request? -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/whatwg/fetch/issues/439
Received on Sunday, 18 December 2016 18:50:10 UTC