首页 新闻 会员 周边

mvc core 视图页中的<environment>

0
悬赏园豆:20 [待解决问题]

在mvc core的视图页中,发现了<environment>标签,以前都没看到过;这几天刚好遇到js和css引用不起作用的问题,大神解析一下。还有mvc core的视图较以前有哪些变化?

 

<head>

<environment names="Development">
        <link rel="stylesheet" href="~/lib/bootstrap/dist/css/bootstrap.css" />
        <link rel="stylesheet" href="~/css/site.css" />
    </environment>
    <environment names="Staging,Production">
        <link rel="stylesheet" href="https://ajax.aspnetcdn.com/ajax/bootstrap/3.3.6/css/bootstrap.min.css"
              asp-fallback-href="~/lib/bootstrap/dist/css/bootstrap.min.css"
              asp-fallback-test-class="sr-only" asp-fallback-test-property="position" asp-fallback-test-value="absolute" />
        <link rel="stylesheet" href="~/css/site.min.css" asp-append-version="true" />
    </environment>
    @Html.ApplicationInsightsJavaScript(TelemetryConfiguration)
</head>

wells_001的主页 wells_001 | 初学一级 | 园豆:173
提问于:2016-08-17 09:09
< >
分享
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册