asp.net - launchSettings.json commandName 用法

标签 asp.net .net asp.net-core

每次我发现一些launchSettings.json文件,它们具有以下结构:

{
  "iisSettings": {
    "windowsAuthentication": false,
    "anonymousAuthentication": true,
    "iisExpress": {
      "applicationUrl": "http://localhost:40088/",
      "sslPort": 0
    }
  },
  "profiles": {
    "IIS Express": {
      "commandName": "IISExpress",
      "launchBrowser": true,
      "environmentVariables": {
        "ASPNETCORE_ENVIRONMENT": "Development"
      }
    },
    "IIS Express (Staging)": {
      "commandName": "IISExpress",
      "launchBrowser": true,
      "environmentVariables": {
        "ASPNETCORE_ENVIRONMENT": "Staging"
      }
    }
  }
}

找到 here .

但是,我找不到关于属性 commandName 的任何文档。 .
commandName的用途是什么? ?

最佳答案

命令名称映射到项目应该如何启动。 Visual Studio 使用它来运行您的项目。

  • IISExpress很明显是用IIS Express来启动项目的。
  • Project表示该项目是直接在命令行上使用 .NET CLI 执行的。

  • command names

    关于asp.net - launchSettings.json commandName 用法,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44645775/

    相关文章:

    html - 使用 CSS 为 I.E 设计样式?

    c# - 如何强制 File.Move/File.Copy 使用特定的网络接口(interface)卡 (NIC) C#?

    c# - IIS 错误 502.5 上的 ASP.NET Core 1.0

    jquery - 使用 jquery ajax 将数组传递给 WebMethod 在 asp.net 中不起作用

    c# - 甚至找不到在 rowdatabound GridView 上添加的复选框控件

    javascript - 将参数传递给 asp.net 页面中的 javascript 函数

    c# - 检查两个对象的字段中是否包含相同的数据

    .net - 使用 SynchronizationContext 将事件发送回 WinForms 或 WPF 的 UI

    asp.net-core - Blazor 独立 WebAssembly 代表登录用户调用安全核心 API

    razor - 在cshtml文件中的C# block 代码之间插入html标签