@flarum/prettier-config
v1.0.0
Published
Flarum's configuration for the Prettier code formatter.
Keywords
Readme
Flarum Prettier Config
Flarum's official configuration for the Prettier code formatter.
For more info about shared Prettier configurations, check out the Prettier documentation.
Usage
- Install
@flarum/prettier-configas a dev dependency:
npm i -D @flarum/prettier-config
yarn add -D @flarum/prettier-config- Add the
prettierkey to yourpackage.json:
// package.json
{
"name": "my-cool-package",
"version": "1.0.0",
"prettier": "@flarum/prettier-config",
// ...
}Extending
You can extend our config with your own custom options, too. Import our config, then spread its require in a .prettierrc.js file.
:warning: Make sure your
package.jsondoesn't have theprettierkey.
// .prettierrc.js
module.exports = {
...require("@flarum/prettier-config"),
semi: false,
};