0
using System.Web;
using System.Web.Optimization;
public class BundleConfig {
public static void RegisterBundles(BundleCollection bundles)
{ // create an object of ScriptBundle and
// specify bundle name (as virtual path) as constructor parameter
ScriptBundle scriptBndl = new ScriptBundle("~/bundles/bootstrap");
//use Include() method to add all the script files with their paths
scriptBndl.Include( "~/Scripts/bootstrap.js", "~/Scripts/respond.js" );
//Add the bundle into BundleCollection
bundles.Add(scriptBndl);
BundleTable.EnableOptimizations = true; } }
For more refereneces:
https://www.aspsnippets.com/Articles/Using-Bundles-ScriptBundle-in-ASPNet-MVC-Razor.aspx
http://www.dotnettricks.com/learn/mvc/aspnet-mvc-4-performance-optimization-with-bundling-and-minification