Prettier Config Planes

raw JSON →
1.0.1 verified Sat Apr 25 auth: no javascript

Shared Prettier configuration package for Team Planes projects. Version 1.0.1 is the current stable release. This package provides a centralized, opinionated Prettier config to ensure consistent code formatting across all projects in the organization. It extends the base Prettier options and can be used by referencing the package name in a project's package.json. The package has no additional dependencies, making it lightweight and easy to adopt. It follows the standard Prettier shared config pattern, allowing for simple integration and overrides.

error Cannot find module 'prettier-config-planes'
cause Package not installed or not in node_modules.
fix
Run 'npm install --save-dev prettier-config-planes' to ensure it's installed.
error Invalid configuration file 'prettier.config.js': require() of ES Module not supported
cause Using ES Module syntax to import the config.
fix
Change the config file to CommonJS (module.exports = require(...)) or use package.json prettier field.
gotcha Cannot import in a JavaScript file via ES import; must use require or package.json reference.
fix Use require('prettier-config-planes') in a CommonJS config file, or set the 'prettier' key in package.json.
gotcha The config may override project-specific settings; check for unintended changes.
fix Review the config options and use overrides in a local prettier.config.js if needed.
npm install prettier-config-planes
yarn add prettier-config-planes
pnpm add prettier-config-planes

Shows how to install and use the shared Prettier config in a project.

// 1. Install the package
npm install --save-dev prettier-config-planes

// 2. Add to package.json:
// "prettier": "prettier-config-planes"

// Or create a prettier.config.js:
module.exports = require('prettier-config-planes');

// Then run prettier:
// npx prettier --check .