FracturedJsonJs v5.0.1 is a JSON formatter for Node.js and browsers that produces highly readable yet compact output by placing arrays/objects on single lines when possible, aligning similar structures into tables, and packing long arrays with multiple items per line. It supports JSON-with-comments (JSONC) and includes TypeScript types. Active development with regular releases; key differentiator is compact table-like alignment vs. standard pretty-printers.
npm install fracturedjsonjsNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows basic usage: create options, instantiate formatter, set options, and reformat a JSON string.
Call JSON.stringify(yourObject) before passing to Reformat() if you have a JavaScript object.
Set all desired options on the options instance before assigning it to Formatter.Options, or create a new options instance per format call.
Use new FracturedJsonOptions() for stability, or FracturedJsonOptions.Recommended() for newest defaults (may change in minor updates).
Run 'npm i fracturedjsonjs' and ensure you are using an ES module (type: module in package.json or .mjs extension).
Change 'const { FracturedJsonOptions } = require("fracturedjsonjs")' to 'import { FracturedJsonOptions } from "fracturedjsonjs"'. The package is ESM-only.Ensure you use 'new Formatter()' and that the import is correct: 'import { Formatter } from "fracturedjsonjs"'.No dependency data recorded yet.