Registry / devops / prettier-plugin-pkgjson

prettier-plugin-pkgjson

JSON →
library0.3.0jsnpmunverified

Prettier plugin for clean and meaningful formatting of package.json files. Version 0.3.0 is the latest stable release. It sorts keys in a logical order, formats JSON consistently, and integrates seamlessly with Prettier. No dependencies. Actively maintained as part of the tunnckoCore opensource monorepo.

devopsserialization
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.

Plugin is auto-loaded by Prettier when listed in plugins array. No explicit import in code.

// In .prettierrc: { "plugins": ["prettier-plugin-pkgjson"] }

Example .prettierrc configuration to enable the plugin and format package.json files.

{ "semi": false, "singleQuote": true, "tabWidth": 2, "trailingComma": "none", "plugins": ["prettier-plugin-pkgjson"] }
Debug
Known footguns
gotchaPlugin requires Prettier v2.x or later; not compatible with Prettier v1.x.
gotchaOnly works on package.json files; other JSON files are unaffected.
gotchaPlugin must be explicitly added to Prettier's plugins array; not auto-detected.
Upgrade
Version history

Breaking-change detection hasn't run for this library yet.

Audit
Security & dependencies

CVE tracking and dependency tree are planned for a later release.

Agent activity
0 hits · last 30 days

No traffic data recorded yet.

Resources