Skip to content

Commit

Permalink
Add missing flags for the astro check command (withastro#8237)
Browse files Browse the repository at this point in the history
Co-authored-by: Atharva <atharvapise19@gmail.com>
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
  • Loading branch information
3 people authored and wpplumber committed May 15, 2024
1 parent 43a95d4 commit d60be02
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions src/content/docs/en/reference/cli-reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,30 @@ Use these flags to customize the behavior of the command.

The command will watch for any changes in your project, and will report any errors.

#### `--root <path-to-dir>`

Specifies a different root directory to check. Uses the current working directory by default.

#### `--tsconfig <path-to-file>`

Specifies a `tsconfig.json` or `jsconfig.json` file to use manually. If not provided, Astro will attempt to find a config, or infer the project's config automatically.

#### `--minimumFailingSeverity <error|warning|hint>`

Specifies the minimum severity needed to exit with an error code. Defaults to `error`.

For example, running `astro check --minimumFailingSeverity warning` will cause the command to exit with an error if any warnings are detected.

#### `--minimumSeverity <error|warning|hint>`

Specifies the minimum severity to output. Defaults to `hint`.

For example, running `astro check --minimumSeverity warning` will show errors and warning, but not hints.

#### `--preserveWatchOutput`

Specifies not to clear the ouput between checks when in watch mode.

<ReadMore>Read more about [type checking in Astro](/en/guides/typescript/#type-checking).</ReadMore>

## `astro sync`
Expand Down

0 comments on commit d60be02

Please sign in to comment.