https://github.com/osdevisnot/prettier
My personal Prettier config
https://github.com/osdevisnot/prettier
Last synced: 21 days ago
JSON representation
My personal Prettier config
- Host: GitHub
- URL: https://github.com/osdevisnot/prettier
- Owner: osdevisnot
- Created: 2019-05-22T15:17:27.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2021-06-10T21:28:44.000Z (about 4 years ago)
- Last Synced: 2025-03-18T05:32:11.507Z (4 months ago)
- Language: JavaScript
- Size: 91.8 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# @osdevisnot/prettier
Sensible Code Formatting Setup in **One Command**
```bash
$ yarn add --dev @osdevisnot/prettier
```or
```bash
npm install --save-dev @osdevisnot/prettier
```## What
Setup `prettier`, `husky` and `pretty-quick` just by installing `@osdevisnot/prettier`
Uses `postinstall` scripts to automatically configure the project.
## How
- This package brings in `prettier`, `husky`, `pretty-quick` and `prettier-plugin-packagejson` as dependencies.
- These dependencies are marked with `*` so that you always get latest versions for these dependencies.
- When installed, we use a `postinstall` script to configure project with sensible defaults:- [x] sets `prettier` property in `package.json` to `@osdevisnot/prettier` if not already defined
- [x] removes `.prettierrc` and `prettier.config.js` if these files exist
- [x] sets `husky` property in `package.json` to use `pretty-quick` on `pre-commit` (if not already defined) :```json
{ "husky": { "hooks": { "pre-commit": "pretty-quick --staged" } } }
```