7

Nuget 在 VS 2012 的单独文件夹中安装 jQuery DataTables -1.9.4。见图。如何将它们与现有的 bundleConfig 捆绑在一起?在此处输入图像描述

我拥有的当前捆绑包是

bundles.Add(new ScriptBundle("~/bundles/jquery").Include(
                        "~/Scripts/jquery-{version}.js"));
   bundles.Add(new ScriptBundle("~/bundles/jqueryui").Include(
                    "~/Scripts/jquery-ui-{version}.js"));
   bundles.Add(new ScriptBundle("~/bundles/jqueryval").Include(
                        "~/Scripts/jquery.unobtrusive*",
                        "~/Scripts/jquery.validate*"));
   bundles.Add(new ScriptBundle("~/bundles/modernizr").Include(
                        "~/Scripts/modernizr-*"));
   bundles.Add(new StyleBundle("~/Content/css").Include("~/Content/site.css"));
   bundles.Add(new StyleBundle("~/Content/themes/base/css").Include(
                        "~/Content/themes/base/jquery.ui.core.css",
                        "~/Content/themes/base/jquery.ui.resizable.css",
                        "~/Content/themes/base/jquery.ui.selectable.css",
                        "~/Content/themes/base/jquery.ui.accordion.css",
                        "~/Content/themes/base/jquery.ui.autocomplete.css",
                        "~/Content/themes/base/jquery.ui.button.css",
                        "~/Content/themes/base/jquery.ui.dialog.css",
                        "~/Content/themes/base/jquery.ui.slider.css",
                        "~/Content/themes/base/jquery.ui.tabs.css",
                        "~/Content/themes/base/jquery.ui.datepicker.css",
                        "~/Content/themes/base/jquery.ui.progressbar.css",
                        "~/Content/themes/base/jquery.ui.theme.css"));
4

1 回答 1

7

您可以将适当的行添加到 .css 包和 .js 包中

.JS

"~/Scripts/DataTables-1.9.4/media/js/jquery.dataTables.js",

.CSS

"~/Content/DataTables-1.9.4/media/css/jquery.dataTables.css",
于 2013-05-09T11:53:30.410 回答