I would like to use Brotli compression for my node application built on express. I deliver content (HTML, CSS and JS) with app.use(express.static('public'))
.
I have found the shrink-ray
module which does Brotli compression perfectly. However, when I install it and run the nsp check
from the node security platform module, I get security vulnerabilities, which makes it impossible to use in my project.
Does anyone know a good alternative to enable Brotli compression on a node app using express? I´ve tried express-static-gzip
but didn´t manage to make it work, it was still gzipped even on a simple tutorial.
enableBrotli
option inexpress-static-gzip
?enableBrotli
option only works if you have the brotli file already available. You can read this article to learn how to use use that option. codeburst.io/express-brotli-webpack-a60773e7ec6c