Compressing packages created by asp.net using "System.Web.Optimization"?

I created packages in my asp.net web solution using the new MS binding and minimization package. Everything is correctly bundled and minimized (the global.asax method is used), but when I deploy to IIS, the package does not receive compression (gzip), I do not want to enable dynamic compression (since it will compress all dynamic content), you just want to compress it packages.

What to do?

What is the mime type for related output, for example, for this package called jQuery:

"http://Myhost/MySite/JQuery?v=1Oof3SDB0npBNcnfiEpdM9WovwwmP-UGKz3QrSQLPPQ1" 

Therefore, I can add the same in the webconfig file in the httpCompression section for gzip compression.

Regards, Gaurav

+4
source share
1 answer

I have enabled dynamic compression in IIS7, there is no other way to compress packages like this except to enable dynamic compression, although it is recommended that you only implement this if you use IIS7 or higher, dynamic compression in lower versions is not optimized and will be taxed your server.

Starting my solution in production after its implementation without any problems.

+3
source

All Articles