0.0.3 • Published 4 years ago

@ocupop/prettier-config v0.0.3

Weekly downloads
2
License
MIT
Repository
github
Last release
4 years ago

Ocupop Prettier Config

Sets up prettier config within npx across projects

Setup

Run the following npx command to install prettier

npx @ocupop/prettier-config

Options

  --version        Show version number                                 [boolean]
  -h, --help       Show help                                           [boolean]
  --remove, --rm   Remove prettier from application   [boolean] [default: false]
  --upgrade, --up  Upgrade prettier config            [boolean] [default: false]

Using

Files

Once installed, the package will add two new files: prettier.config.js where we can add addtional config options per project, and .prettierignore in which we can ignore files/directories when using prettier.

Scripts

Within package.json two new scrips are installed.

$ yarn checkFormat  # will run prettier and validate files
$ yarn format       # formats all files (with specified extensions) 

Prettier Extension

By default we do not require that the pretty extension be installed. Simply running yarn format will run prettier within our code base. However a step up, we can install the prettier extension which will help format as you develop.

With it installed you can setup (under settings) "editor.formatOnSave": true which will format your files each save. You can also run Format Document from your command pallet

Publishing

$ npm login <login with ocupop creds>
# [ ] Make sure to push changes to git first
# [ ] Make sure to bump the version number
$ npm publish
0.0.3

4 years ago

1.0.19

4 years ago

1.1.0

4 years ago

1.0.18

4 years ago

1.0.17

4 years ago

1.0.16

4 years ago

0.0.1

4 years ago

0.0.2

4 years ago

1.0.15

4 years ago

1.0.14

4 years ago

1.0.13

4 years ago

1.0.11

4 years ago

1.0.12

4 years ago

1.0.10

4 years ago