Open
Description
In order to track progress of a fetch GET request(in a similar way to onprogress
events of XMLHttpRequest
) it is possible to read the body of a request with a ReadableStream
and retrieve the total size of the request body from Content-Length
header.
However, if the request is compressed using the Content-Enconding
header the Content-Length
does not give the total uncompressed size of the request body but the size of the compressed request body.
It would be nice to have an interface to get the total size of the uncompressed body in order to properly track the progress of a request. There is the FetchObserver
(#607) proposal but it doesn't seem to have gained any traction.