Files
cheatsheet-tldr/tldr/ng-lint
2026-01-23 00:23:11 +00:00

31 lines
648 B
Plaintext

---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# ng lint
> Check Angular project code for style and errors using the configured linter.
> Note: Linting requires setup via `ng add`.
> More information: <https://angular.dev/cli/lint>.
- Lint all projects in the workspace:
`ng lint`
- Lint a specific project:
`ng lint {{project_name}}`
- Automatically fix linting errors:
`ng lint {{project_name}} --fix`
- Return a successful exit code even if lint errors are found:
`ng lint {{project_name}} --force`
- Use a specific output format:
`ng lint {{project_name}} --format {{stylish|json|...}}`