相关疑难解决方法(0)

只有'amd'和'系统'模块与--out一起支持

在VSCode中构建typescript时,我收到以下错误:

错误TS6082:在--out旁边只支持'amd'和'system'模块.

我的设置如下:

tsconfig.json

{
    "compilerOptions": {
        "target": "ES5",
        "module": "commonjs",
        "out": "current/game.js",
        "removeComments": true,
        "sourceMap": false
    }
}
Run Code Online (Sandbox Code Playgroud)

.vscode/tasks.json:

{
    "version": "0.1.0",

    // The command is tsc. Assumes that tsc has been installed using npm install -g typescript
    "command": "tsc",

    // The command is a shell script
    "isShellCommand": true,

    // Show the output window only if unrecognized errors occur.
    "showOutput": "silent",

    // args is the HelloWorld program to compile.
    "args": [],

    // use the standard tsc problem matcher to …
Run Code Online (Sandbox Code Playgroud)

typescript phaser-framework visual-studio-code

41
推荐指数
1
解决办法
2万
查看次数