プロジェクトでは.NET MVC4
どのように@Styles.Render
機能しますか?
つまり、@Styles.Render("~/Content/css")
どのファイルで呼び出されるのですか?
フォルダー内に「css」というファイルやフォルダーがありませんContent
。
ベストアンサー1
BundleConfig
フォルダー内のクラス内で宣言されている特定のバンドルに含まれるファイルを呼び出しますApp_Start
。
この特定のケースでは、呼び出しは@Styles.Render("~/Content/css")
「~/Content/site.css」を呼び出します。
bundles.Add(new StyleBundle("~/Content/css").Include("~/Content/site.css"));