Express gzip static content

前端 未结 5 1722
南方客
南方客 2020-12-13 04:23

Express and connect appeared to have removed their gzip functions because they were too inefficient. Are there any reliable solutions to gzip with express-js currently?

5条回答
  •  春和景丽
    2020-12-13 04:40

    I have also searched npm and found for example:

    • https://github.com/tomgallacher/gzippo

      gzippo pronounced g-zippo is a gzip middleware for Connect using Compress for better performance.

    Gzippo has recently been developed(2 days ago) which I think is a good thing. I can't tell you about production usage. You should test/benchmark it yourself. I would also probably use a CDN for a live site or Nginx to host my static files instead of some nodejs module.

提交回复
热议问题