@mheob/prettier-config
v3.3.3
Published
My personal configuration for prettier.
Downloads
568
Readme
My personal Prettier config
To make my configurations a bit easier I share my Prettier config.
Install
With NPM
npm install -D @mheob/prettier-config
With YARN
yarn add -D @mheob/prettier-config
With PNPM
pnpm add -D @mheob/prettier-config
With BUN
bun add -D @mheob/prettier-config
Usage
If you need to override some settings you can do it this way:
// .prettierrc.cjs
/** @type {import('prettier').Config} */
module.exports = {
...require('@mheob/prettier-config'),
semi: false,
useTabs: false,
};
Ruleset
This configuration uses these styles:
/** @type {import('prettier').Config} */
module.exports = {
arrowParens: 'avoid',
endOfLine: 'lf',
printWidth: 100,
proseWrap: 'always',
semi: true,
singleQuote: true,
trailingComma: 'all',
useTabs: true,
// eslint-disable-next-line perfectionist/sort-objects
overrides: [
{
files: '*.{yaml,yml}',
options: {
printWidth: 130,
singleQuote: false,
useTabs: false,
},
},
{
files: '*.md',
options: {
printWidth: 130,
},
},
],
};