ESLint and Prettier are configured
Why it matters
Without ESLint and Prettier, code style diverges with every commit. Reviewers spend time on formatting comments instead of logic. Style inconsistencies accumulate until they generate real merge conflicts. ISO 25010 maintainability.analysability and modifiability both degrade as the codebase becomes harder to read and predict. Projects bootstrapped with create-next-app get a default ESLint config that is never customized — it provides minimal coverage and gives a false impression that linting is configured.
Severity rationale
Medium because absent linting and formatting tools allow consistent, preventable code quality issues to accumulate that slow every code review and future refactoring.
Remediation
Install and configure both tools:
npm install -D eslint prettier eslint-config-prettier
npx eslint --init
echo '{}' > .prettierrc
For Next.js, extend the built-in config and add the Prettier integration:
// .eslintrc.json
{
"extends": ["next/core-web-vitals", "prettier"]
}
Add lint and format scripts to package.json. Pair with git pre-commit hooks (see the git-hooks check) so neither tool is optional.
Detection
-
ID:
eslint-prettier -
Severity:
medium -
What to look for: Check for ESLint configuration:
.eslintrc.js,.eslintrc.json,.eslintrc.yaml,eslint.config.js(flat config), or aneslintConfigkey inpackage.json. Check for Prettier configuration:.prettierrc,.prettierrc.json,.prettierrc.js,prettier.config.js, or aprettierkey inpackage.json. Also check that ESLint and Prettier appear indevDependencies. Note: some frameworks (Next.js) include ESLint by default — verify it's actually configured, not just installed. -
Pass criteria: Count all linting and formatting configuration files in the project. Both ESLint and Prettier (or a unified formatter like Biome) are installed and have configuration files present. The ESLint config references at least 1 installed rules/plugins. Extract and quote the extends or plugins array from the ESLint config to verify it is not empty. Report which tools are configured even on pass.
-
Fail criteria: Either ESLint or Prettier (or both) is absent or not configured. A project with
eslintinstalled but no config file does not pass. Do NOT pass when a config file exists but is empty or contains no rules. -
Cross-reference: For git hooks that enforce linting before commit, see the git-hooks check in this audit.
-
Skip (N/A) when: The project uses a non-JavaScript/TypeScript language that has its own equivalent tooling (e.g.,
gofmtfor Go,rustfmtfor Rust,blackfor Python) — evaluate that tooling instead. Signal: nopackage.jsonin the project. -
Detail on fail:
"No Prettier configuration found (.prettierrc or prettier.config.js absent, no prettier key in package.json). ESLint installed but config file is missing — likely the Next.js default that was never customized."or"Neither ESLint nor Prettier configured — no linting or formatting tooling set up." -
Remediation: Without automated linting and formatting, code style diverges rapidly across files and contributors. Code review time increases because reviewers must manually check what tools would catch automatically.
Set up ESLint and Prettier:
npm install -D eslint prettier eslint-config-prettier npx eslint --init # interactive setup echo '{}' > .prettierrc # minimal config, uses defaultsFor Next.js, extend the built-in config:
// .eslintrc.json { "extends": ["next/core-web-vitals", "prettier"] }Add format and lint scripts to
package.json:"scripts": { "lint": "eslint . --ext .ts,.tsx", "format": "prettier --write ." }
External references
- iso-25010:2011 · maintainability.analysability — Analysability
- iso-25010:2011 · maintainability.modifiability — Modifiability
Taxons
History
- 2026-04-18·v1.0.0·Initial import from code-maintainability·automated