@jscpd/html-reporter
v4.2.4
Published
html reporter for jscpd
Readme
@jscpd/html-reporter
HTML reporter for jscpd — generates an interactive HTML report with per-format statistics, a duplication graph, and syntax-highlighted clone diff views.
Output directory: <output-dir>/html/
Entry point: <output-dir>/html/index.html
Raw data: <output-dir>/html/jscpd-report.json
Installation
npm install @jscpd/html-reporterUsage
jscpd --reporters html --output ./reports /path/to/sourceThen open ./reports/html/index.html in a browser.
Programmatic usage
import { IClone, IOptions, IStatistic } from '@jscpd/core';
import HtmlReporter from '@jscpd/html-reporter';
const options: IOptions = { output: './reports' };
const reporter = new HtmlReporter(options);
reporter.report(clones, statistic);
// writes ./reports/html/index.html and ./reports/html/jscpd-report.jsonLicense
MIT © Andrey Kucherenko
