@brattonross/prettier-config
Personal, opinionated Prettier configuration used by @brattonross.
Usage
1. Install
npm install --save-dev @brattonross/prettier-config
2. Apply configuration
You can apply the configuration in various ways, but the simplest is to reference it in your package.json
:
{
"name": "my-cool-library",
"version": "9000.0.1",
"prettier": "@brattonross/prettier-config"
}
Read more about the other ways you can use the configuration here.
3. Run Prettier
How you choose to run Prettier is up to you. Personally I like to configure my editor to run Prettier on save, and for projects where I am collaborating with others I will use tools like yorkie or husky to ensure that everyone has their code formatted before it gets committed.
Related
You can find my personal ESLint configuration here.