OWASP / OWASP/cve-lite-cli

chore: add Prettier for consistent code formatting

Open
#446 0 comments 0 reactions 1 assignee View on GitHub

@sonukapoor is already working on this.

Since May 25, 2026.

enhancement in-house
Dominant language
TypeScript
Stars
715
Forks
145
Avg merge
21h 39m
Merged PRs (30d)
66

Description

Note: this is an in-house item already being handled by the maintainer - not open for contribution. Filed for tracking only.

Add Prettier as a dev dependency to enforce consistent code formatting across all source files.

Blocked on: #443 (adds braces to single-line if statements in src/cli/args.ts) — merge that first to avoid conflicts.

Work:

  • Install prettier as a dev dependency
  • Add .prettierrc with project style rules (single quotes, 2-space indent, trailing commas, printWidth 120, arrowParens always)
  • Run Prettier on the full codebase in a single formatting commit
  • Add format and format:check scripts to package.json
  • Add a format check step to .github/workflows/ci.yml
  • Update CONTRIBUTING.md to document the npm run format workflow

Prettier config:

{
  "semi": true,
  "singleQuote": true,
  "tabWidth": 2,
  "trailingComma": "all",
  "printWidth": 120,
  "arrowParens": "always"
}

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.