0
私は2つのcssファイルを持っています。どちらも右から左の言語のフィックスであり、右から左へのカルチャーが選択されている場合はすべてのページに存在し、そうでない場合は存在しません。レイアウトファイルにbundleconfigに条件付きCSSを追加
現在の定義:
<environment names="Development">
<link rel="stylesheet" href="~/css/site.css" />
</environment>
<environment names="Staging,Production">
<link rel="stylesheet" href="~/css/site.min.css" asp-append-version="true" />
</environment>
bundleconfig.json:
{
"outputFileName": "wwwroot/css/site.min.css",
// An array of relative input file paths. Globbing patterns supported
"inputFiles": [
"wwwroot/css/site.css"
]
},
{
"outputFileName": "wwwroot/js/site.min.js",
"inputFiles": [
"wwwroot/js/site.js"
],
// Optionally specify minification options
"minify": {
"enabled": true,
"renameLocals": true
},
// Optionally generate .map file
"sourceMap": false
}
必要なときにバンドルに含める方法はありますか?私は別にそれを含めたくない。