As has often been pointed out, the various .cache.html files produced by pyjsbuild can be quite large, often several Mbytes. Pyjscompressor can reduce them to about half their initial length but that's still quite big. If the server does gzip compression that will presumably reduce them quite a lot further. Unfortunately, many hosting services do not configure their servers to do gzip compression, which is a pity since most browsers will happily handle such files.
I recently came across the idea of using php to do the compression: http://www.whatsmyip.org/http-compression-test/phpgzip/ and that works very nicely with a conventional website, just needing one line of php code in each page (and changing the extension to .php, if the server can't be configured to execute .html files as php). I am wondering whether it would be possible to get this trick to work with pyjs. It's clearly not enough to do it on the root html file because the .cache.html files don't get compressed. Does anyone understand well enough how these files get loaded to express a view on whether it would be possible to (optionally) modify the loader to load versions of the cache files containing the compression code and having the php extension?
