I’m using the Meleze.Web library for my web application and I want to add the compression only on release builds.
I tried to do a web.config transformation but in the Web.Release.config file, when I try to do
<configuration>
<system.web.webPages.razor>
<host xdt:Transform="Replace" factoryType="Meleze.Web.Razor.MinifyHtmlWebRazorHostFactory, Meleze.Web, Version=1.4.0.3, Culture=neutral, PublicKeyToken=0a868b5321967eda" />
</system.web.webPages.razor>
</configuration>
gives me an error saying that the :Transform is not declared. Any help would be appreciated. Please note, this is the Web.Config in the Views folder.
For me, its working perfectly. Steps that I followed are here:
PM> Install-Package Meleze.WebView/Web.configand replace the<host...../>line inside<system.web.webPages.razor>with<host factoryType="Meleze.Web.Razor.MinifyHtmlWebRazorHostFactory, Meleze.Web, Version=1.4.0.3, Culture=neutral, PublicKeyToken=0a868b5321967eda" />That’s all I did. Btw, I am using MVC 4.