GZIP in .net core not working : <p>I'm attempting to add Gzip middleware to my ASP.net core app. </p>

<p>I have added the following package : </p>

<blockquote>
  <p>"Microsoft.AspNetCore.ResponseCompression": "1.0.0"</p>
</blockquote>

<p>In my startup.cs for the Configure Services method I have the following : </p>

<pre><code>public void ConfigureServices(IServiceCollection services)
{
    services.Configure&lt;GzipCompressionProviderOptions&gt;(options =&gt; options.Level = CompressionLevel.Fastest);
    services.AddResponseCompression(options =&gt;
    {
        options.Providers.Add&lt;GzipCompressionProvider&gt;();
    });

    services.AddMvc();
}
</code></pre>

<p>In my Configure method I have the following : </p>

<pre><code>public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
{
    loggerFactory.AddConsole(Configuration.GetSection("Logging"));
    loggerFactory.AddDebug();

    app.UseResponseCompression();
    app.UseMvc();
}
</code></pre>

<p>However when I try and load a page, it doesn't come through as Gzip compressed. I have used both a string response and outputting a view. The response headers in chrome look like : </p>

<p><a href="https://i.stack.imgur.com/5Vh4T.png"><img src="https://i.stack.imgur.com/5Vh4T.png" alt="enter image description here"></a></p>

<p>I am on a windows machine developing in visual studio. When running the app I have tried just running from Visual Studio (Via F5), and also using the "dotnet run" command from command line. Neither output GZip compression. </p>
