- From: glococo <notifications@github.com>
- Date: Thu, 28 Sep 2017 18:28:29 +0000 (UTC)
- To: whatwg/fetch <fetch@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Thursday, 28 September 2017 18:28:51 UTC
Hi,
I found no way of observing the progress on Upload fetch()
var garbage = new Float64Array(new ArrayBuffer(104856))
for (let i=0; i<garbage.length; i++) garbage[i] = Math.random()
var gArray = []
for (let i=0; i<100; i++) gArray.push(garbage);
var gBlob = new Blob(gArray) //10MB
var controller = new FetchController(); // FF55 or AbortController() in Firefox58
var signal = controller.signal;
fetch( "/?action=upload",{ signal, observe(observer) { observer.onresponseprogress=e=>console.log(e);observer.onrequestprogress=e=>console.log(e);observer.onstatechange=n=>console.log(observer.state) }, method:"POST", body:gBlob } )
The only working observer is "state" ( Firefox 55/58 Ubuntu)
--
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/607#issuecomment-332923871
Received on Thursday, 28 September 2017 18:28:51 UTC