@lokiverse/prettier-config-experimental

0.0.0 • Public • Published
Lokicoule Prettier Configuration

Prettier configuration with minimal rules.

Installation

pnpm add -D @lokicoule/prettier-config

Usage

Update package.json:

{
  "prettier": "@lokicoule/prettier-config"
}

Configuration

{
  // Use official Prettier schema for validation
  "$schema": "https://json.schemastore.org/prettierrc",

  // Line length before wrapping
  // Default: 80
  "printWidth": 100,

  // Use single quotes instead of double quotes
  // true  => const x = 'test'
  // false => const x = "test"
  "singleQuote": true,

  // If you quote a property, quote all properties
  // "as-needed"  => { foo: "bar", "quotedFoo": "bar" }
  // "consistent" => { "foo": "bar", "quotedFoo": "bar" }
  // "preserve"   => { foo: "bar", "quotedFoo": "bar" }
  "quoteProps": "consistent",

  // Put each HTML attribute on a new line
  // true:
  // <button
  //   class="btn"
  //   onClick={click}>
  //   Button
  // </button>
  "singleAttributePerLine": true,

  // Control whitespace sensitivity in HTML
  // "css"     => Respect CSS display property
  // "strict"  => Whitespace is considered significant
  // "ignore"  => Whitespace is considered insignificant
  "htmlWhitespaceSensitivity": "ignore"
}

Package Sidebar

Install

npm i @lokiverse/prettier-config-experimental

Weekly Downloads

3

Version

0.0.0

License

MIT

Unpacked Size

3.76 kB

Total Files

4

Last publish

Collaborators

  • lokicoule