I donβt think there is a way to get this time, especially in your own Javascript code: I believe that decompression is performed at a much lower level (for example, somewhere around the boot / network level of the browser) than rendering the execution page of your Javascript code.
This would be the best solution so that this compression is completely transparent to the upper layers: when rendering pages or executing JS code, it is absolutely not necessary for the browser to know that it was received in a compressed form.
Maybe a solution, especially with Firefox, should have developed some extension?
Given that Firebug, for example, is able to "connect" to the network layer to display the information that we get on the "Network" tab, I suppose you could do something like this?
source share