【问题标题】:the --harmony flag in the args parameter seems not to workargs 参数中的 --harmony 标志似乎不起作用
【发布时间】:2015-05-04 08:19:53
【问题描述】:

args 参数中节点的 --harmony 标志似乎不起作用。我不能使用胖数组函数。 这里是lounch.json的一部分

"configurations": [
    {
        // Name of configuration; appears in the launch configuration drop down menu.
        "name": "Launch app.js",
        // Type of configuration. Possible values: "node", "mono".
        "type": "node",
        // Workspace relative or absolute path to the program.
        "program": "./app.js",
        // Automatically stop program after launch.
        "stopOnEntry": true,
        // Command line arguments passed to the program.
        "args": ["--harmony"],
        // Workspace relative or absolute path to the working directory of the program being debugged. Default is the current workspace.
        "cwd": ".",
        // Workspace relative or absolute path to the runtime executable to be used. Default is the runtime executable on the PATH.
        "runtimeExecutable": null,
        // Environment variables passed to the program.
        "env": { }
    }, 
    {
        "name": "Attach",
        "type": "node",
        // TCP/IP address. Default is "localhost".
        "address": "localhost",
        // Port to attach to.
        "port": 5858
    }
]

有没有办法自己解决问题?

【问题讨论】:

    标签: node.js visual-studio-code


    【解决方案1】:

    “args”参数不是针对节点进程的,而是针对应用程序的参数。 我自己对此感到困惑,文档应该更清楚。

    有关解决方法,请参阅此问题:How to start nodejs with custom params from vscode

    【讨论】:

      猜你喜欢
      • 2021-12-09
      • 2011-09-19
      • 2020-12-08
      • 2021-07-09
      • 2015-04-26
      • 2020-05-02
      • 1970-01-01
      • 2011-09-13
      • 1970-01-01
      相关资源
      最近更新 更多