Shared Prettier configuration for Homebound projects.
yarn add -D @homebound/prettier-config prettierAdd to your package.json:
{
"prettier": "@homebound/prettier-config"
}To override settings, create a .prettierrc.js file:
const homeboundConfig = require("@homebound/prettier-config");
module.exports = {
...homeboundConfig,
// your overrides here
};This config includes:
trailingComma: "all"printWidth: 120- prettier-plugin-organize-imports for automatic import sorting
Add a check step to your CI:
prettier --check .Or format all files:
prettier --write .