require-readme-badges
Require at least one status badge in the README file.
Targeted pattern scopeâ
This rule reads README.md, README, readme.md, or README.rst and checks
whether the file contains an inline image link pointing to an https:// URL,
which is the standard Markdown syntax for badges (e.g. ).
What this rule reportsâ
This rule reports when the README does not contain any recognisable badge.
Why this rule existsâ
Badges provide at-a-glance health signals for a repository: build status, test coverage, current version, license, and dependency freshness. They are especially important for open-source projects because contributors and potential adopters rely on them to quickly assess project health without reading through CI configuration. A README without any badges is harder to evaluate at a glance.
â Incorrectâ
# my-library
A useful library with no visual health indicators.
## Installation
`npm install my-library`
â Correctâ
# my-library
[](https://github.com/owner/repo/actions/workflows/ci.yml)
[](https://www.npmjs.com/package/my-library)
A useful library.
ESLint flat config exampleâ
import repoPlugin from "eslint-plugin-repo";
export default [
repoPlugin.configs.all,
{
plugins: { "repo-compliance": repoPlugin },
rules: {
"repo-compliance/require-readme-badges": "warn",
},
},
];
When not to use itâ
Disable this rule if your project is internal or private and does not expose public CI/badge services, or if your project intentionally keeps the README minimal.
Rule catalog ID: R049