Reporters

Badge Reporter

Generate SVG badges for your README.

Installation

The badge reporter is included in jscpd v5 by default — no separate installation needed.

Usage

jscpd --reporters badge ./src

Output

Generates an SVG badge showing duplication percentage:

Adding to README

After generating the badge:

![jscpd](./report/jscpd-badge.svg)

Configuration

.jscpd.json
{
  "reporters": ["badge", "console"],
  "output": "./badges"
}