{
  "id": "tsc",
  "name": "TypeScript compiler (tsc)",
  "description": "The TypeScript compiler, which type-checks and compiles TypeScript to JavaScript.",
  "homepage": "https://www.typescriptlang.org",
  "executables": [
    "tsc"
  ],
  "commands": {
    "format": 1,
    "label": "Compile TypeScript",
    "description": "Type-check or compile a project or files. Only common compiler flags are here; other options belong in tsconfig.json. Note a project cannot be combined with input files.",
    "quality": "ai-draft",
    "base": "fig:tsc",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": false,
      "short_attached": true,
      "short_bundles": false
    },
    "source": [
      {
        "id": "fig",
        "kind": "completion",
        "url": "https://github.com/withfig/autocomplete/blob/master/src/tsc.ts",
        "license": "MIT"
      }
    ],
    "field": [
      {
        "id": "files",
        "label": "Input files",
        "description": "Leave empty to use the project config; cannot be combined with --project.",
        "type": "path",
        "position": 0,
        "multiple": true,
        "path": {
          "kind": "file",
          "role": "input"
        },
        "sources": [
          "fig"
        ]
      },
      {
        "id": "project",
        "label": "Project (tsconfig)",
        "type": "path",
        "option": [
          "--project"
        ],
        "path": {
          "kind": "any",
          "role": "input"
        },
        "sources": [
          "fig"
        ]
      },
      {
        "id": "no_emit",
        "label": "Type-check only",
        "type": "boolean",
        "option": [
          "--noEmit"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "watch",
        "label": "Watch mode",
        "type": "boolean",
        "option": [
          "--watch"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "init",
        "label": "Create tsconfig.json",
        "type": "boolean",
        "option": [
          "--init"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "target",
        "label": "Target",
        "type": "string",
        "option": [
          "--target"
        ],
        "suggestions": [
          {
            "value": "ES5",
            "label": "ES5"
          },
          {
            "value": "ES2015",
            "label": "ES2015"
          },
          {
            "value": "ES2020",
            "label": "ES2020"
          },
          {
            "value": "ESNext",
            "label": "ESNext"
          }
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "module",
        "label": "Module",
        "type": "string",
        "option": [
          "--module"
        ],
        "suggestions": [
          {
            "value": "CommonJS",
            "label": "CommonJS"
          },
          {
            "value": "ESNext",
            "label": "ESNext"
          },
          {
            "value": "UMD",
            "label": "UMD"
          },
          {
            "value": "AMD",
            "label": "AMD"
          }
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "out_dir",
        "label": "Output directory",
        "type": "path",
        "option": [
          "--outDir"
        ],
        "path": {
          "kind": "directory",
          "role": "output"
        },
        "sources": [
          "fig"
        ]
      },
      {
        "id": "strict",
        "label": "Strict checks",
        "type": "boolean",
        "option": [
          "--strict"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "declaration",
        "label": "Emit .d.ts",
        "type": "boolean",
        "option": [
          "--declaration"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "source_map",
        "label": "Source maps",
        "type": "boolean",
        "option": [
          "--sourceMap"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "skip_lib_check",
        "label": "Skip lib check",
        "type": "boolean",
        "option": [
          "--skipLibCheck"
        ],
        "sources": [
          "fig"
        ]
      }
    ],
    "task": [
      {
        "id": "check",
        "label": "Type-check project",
        "set": {
          "no_emit": [
            true
          ]
        },
        "fields": [
          "project",
          "no_emit",
          "skip_lib_check"
        ],
        "required": []
      },
      {
        "id": "build",
        "label": "Compile project",
        "fields": [
          "project",
          "out_dir",
          "source_map",
          "declaration"
        ],
        "required": []
      },
      {
        "id": "watch",
        "label": "Watch project",
        "set": {
          "watch": [
            true
          ]
        },
        "fields": [
          "project",
          "watch",
          "no_emit"
        ],
        "required": []
      }
    ],
    "group": [
      {
        "id": "basic",
        "label": "Basic",
        "fields": [
          "files",
          "project",
          "no_emit",
          "watch",
          "strict"
        ]
      },
      {
        "id": "advanced",
        "label": "Advanced",
        "fields": [
          "init",
          "target",
          "module",
          "out_dir",
          "declaration",
          "source_map",
          "skip_lib_check"
        ]
      }
    ]
  }
}
