@slhs/prettier-config

4.0.1 • Public • Published

@slhs/prettier-config

This is the SLHS Prettier configuration.

npm Version Build Status

Install

npm install --save-dev @slhs/prettier-config

Be sure to install the appropriately versioned prettier peer dependency as well.

Usage

Follow the Prettier documentation on sharing configurations.

Examples

package.json

{
  "prettier": "@slhs/prettier-config",
  "scripts": {
    ...
    "format": "prettier --cache --write .",
    "format:check": "prettier --cache --check .",
    ...
  }
}

.prettierignore

# .gitignore and...

.changeset
.vscode
package.json
package-lock.json

Customization

If you need to customize the configuration, you can use a dedicated Prettier config file instead of the one-liner in package.json:

prettier.config.js

import slhsConfig from '@slhs/prettier-config';

/** @type {import("prettier").Options} */
export const config = {
  ...slhsConfig,
  // overrides here
};

export default config;

Package Sidebar

Install

npm i @slhs/prettier-config

Weekly Downloads

2,362

Version

4.0.1

License

none

Unpacked Size

4.06 kB

Total Files

3

Last publish

Collaborators

  • slhs