Registry / testing / cucumber-json-report-formatter

cucumber-json-report-formatter

JSON →
library0.1.5jsnpmunverified

A library (v0.1.5) that converts Cucumber NDJSON messages generated by @badeball/cypress-cucumber-preprocessor into standard Cucumber JSON report format. Requires Node.js 24+. Lightweight utility with no external dependencies. Actively developed but young; TypeScript types included.

npm install cucumber-json-report-formatter
INSTALL
IMPORT
SIG · CUCUMBER-JSON-REPO
C
cucumber-json-report-formatter
testingjavascriptv0.1.5
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Formatter
import { Formatter } from 'cucumber-json-report-formatter'
const Formatter = require('cucumber-json-report-formatter')
Package is ESM-only; CommonJS require will fail.
Formatter
import { Formatter } from 'cucumber-json-report-formatter'
import Formatter from 'cucumber-json-report-formatter'
Formatter is a named export, not default.
Formatter
import type { Formatter } from 'cucumber-json-report-formatter'
If only type used, import type to avoid runtime inclusion.

Converts NDJSON messages from @badeball/cypress-cucumber-preprocessor into standard Cucumber JSON report.

import { Formatter } from 'cucumber-json-report-formatter'; async function generateReport() { const formatter = new Formatter(); await formatter.parseCucumberJson('./cucumber-messages.ndjson', './reports/cucumber-report.json'); console.log('Report generated'); } generateReport().catch(console.error);
Debug
Known issues
breakingNode.js version requirement >=24.0.0
fix
Upgrade Node.js to v24 or later.
affects: >=0.0.0
deprecatedNo default export; only named export Formatter.
fix
Use import { Formatter } instead of import Formatter.
affects: >=0.1.0
Errors
Common errors & fixes
Error [ERR_REQUIRE_ESM]: require() of ES Module not supported
Using CommonJS require() with ESM-only package.
fix
Switch to import statement or use dynamic import().
SyntaxError: Unexpected token 'export'
Node.js version <24 does not support ESM syntax.
fix
Upgrade Node.js to 24+.
TypeError: Formatter is not a constructor
Default import used instead of named import.
fix
Use import { Formatter } from 'cucumber-json-report-formatter'.
Upgrade
Version history
0.1.5latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
22 hits · last 30 days
node
20
Bingbot
1
Resources
cucumber-json-report-formatter — npm install cucumber-json-report-formatter · libregistry