@peralva/prettier-config
v1.0.15
Published
Prettier Configuration
Downloads
1
Readme
@peralva/prettier-config
Prettier Configuration
Installation
npm install -D @peralva/prettier-config
Usage
Add to package.json
:
{
"prettier": "@peralva/prettier-config"
}
If you don’t want to use package.json, you can use any of the supported extensions to export a string, e.g. .prettierrc
:
"@peralva/prettier-config"
Extending the config
To extend the configuration to overwrite some properties from the configuration, import the file in a .prettierrc.mjs
or prettier.config.mjs
file and export the modifications, e.g:
import prettierConfig from '@peralva/prettier-config';
/**
* @type {import('prettier').Config}
*/
export default {
...prettierConfig,
semi: false,
};
For more details, see https://prettier.io/docs/en/configuration