To enable minification, ensure the following:

1. Config.asax, register the BundlesConfig:

protected void Application_Start()
{
         BundlesConfig.RegisterBundles(BundleTable.Bundles);
}

2. BundleConfig.cs, include the scripts and enable optimizations:

public static void RegisterBundles(BundleCollection bundles)
{
  bundles.Add(new ScriptBundle("~/bundles/jquery").Include(
    "~/Scripts/jquery-{version}.js"));
 
BundleTable.EnableOptimizations = true;
}

3. main.html, register the scripts:

@section scripts {
       @Scripts.Render("~/bundles/jquery")
}

4. In addition, the minification process, change $scope and $q into random variables. Since this does not tell Angular what to inject, the solution is to declare your dependencies wrapped in []:

angular.module("MyApp")
       .controller("MyCtrl", ["$scope", "$q", function($scope, $q) {
  // your code
}])

This is just the steps you need to enable minification.