asp.net-optimization

ASP.NET Bundles how to disable minification

China☆狼群 提交于 2019-11-26 06:36:19
I have debug="true" in both my web.config(s) , and I just don't want my bundles minified, but nothing I do seems to disable it. I've tried enableoptimisations=false , here is my code: //Javascript bundles.Add(new ScriptBundle("~/bundles/MainJS") .Include("~/Scripts/regular/lib/mvc/jquery.validate.unobtrusive.js*") .Include("~/Scripts/regular/lib/mvc/jquery.validate*") .Include("~/Scripts/regular/lib/bootstrap.js") .IncludeDirectory("~/Scripts/regular/modules", "*.js", true) .IncludeDirectory("~/Scripts/regular/pages", "*.js", true) .IncludeDirectory("~/Scripts/regular/misc", "*.js", true)); /

ASP.NET MVC framework 4.5 CSS bundle does not work on the hosting

左心房为你撑大大i 提交于 2019-11-26 05:15:09
问题 I am runing an App on app harbor written in MVC4. A bundle of css files doesn\'t work. In my local computer in debug mode I see the code of the App and I see the files. The App works as expected. <link href=\"/Content/css/home/basic-jquery-slider.css\" rel=\"stylesheet\"/> <link href=\"/Content/css/home/Home.css\" rel=\"stylesheet\"/> When I upload the app to Appharbor I see the bundle in the code but the App doesn\'t work. <link href=\"/Content/css/home?v=zhVOIpUNuvCOZhJyBcQWpMlozayor4te6k

How to add reference to System.Web.Optimization for MVC-3-converted-to-4 app

隐身守侯 提交于 2019-11-26 03:00:03
问题 I\'m trying to use the new bundling feature in a project I recently converted from MVC 3 to MVC 4 beta. It requires a line of code in global.asax, BundleTable.Bundles.RegisterTemplateBundles(); , which requires using System.Web.Optimization; at the top. When I do this, I get the red squiggly lines that say, \"Are you missing an assembly reference?\" When I try and add reference, and click on the .NET tab in the dialog, sort from A-Z, I do not see System.Web.Optimization . How do I add this

MVC4 StyleBundle not resolving images

别等时光非礼了梦想. 提交于 2019-11-25 23:24:36
My question is similar to this: ASP.NET MVC 4 Minification & Background Images Except that I want to stick with MVC's own bundling if I can. I'm having a brain crash trying to figure out what the correct pattern is for specifying style bundles such that standalone css and image sets such as jQuery UI work. I have a typical MVC site structure with /Content/css/ which contains my base CSS such as styles.css . Within that css folder I also have subfolders such as /jquery-ui which contains its CSS file plus an /images folder. Image paths in the jQuery UI CSS are relative to that folder and I don't