question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

compression gzip not working (expressjs - compression library)

See original GitHub issue

I use from compression library and still not working… this is my config :

const app = express();

app.use(compression());

app.use("/public", express.static(path.join(path.resolve(__dirname, '../../public'))));

noat4

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
dougwilsoncommented, Nov 7, 2016
app.use(compression({
  filter: function () { return true; }
}));
0reactions
dougwilsoncommented, Oct 29, 2016

Hi @alirezavalizade I’m not sure I understand.

Read more comments on GitHub >

github_iconTop Results From Across the Web

compression gzip not working (expressjs - compression library)
according to this link By default, this module does not compress responses that contain already compressed assets, like JPEG images.
Read more >
Express compression middleware
The following compression codings are supported: deflate; gzip. Install. This is a Node.js module available through the npm registry. Installation is done using ......
Read more >
Gzip compression with Node.js - Medium
Compression in Node.js and Express.js decreases the amount of downloadable data from a website or app. By using this compression, we can improve...
Read more >
How to do compression with Gzip in Node.js ? - GeeksforGeeks
Open the browser and go to the URL http://localhost:8080/, Without compression, the response returned by the server will weigh around 16 kB, as ......
Read more >
gZip compression with Node Express.js server explained ...
gZip compression with Node Express.js server explained. Enable Text Compression.In this video we will ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found