sajad torkamani

Install package:

npm i -D prettier

Create .prettierrc:

touch .prettierrc
{
  "semi": false,
  "singleQuote": true
}

(Optional) Add NPM scripts:

{
  "format:check": "prettier --check src/",
  "format:fix": "prettier --write src/"
}

Run format script:

npm run format:fix

Leave a comment

Your email address will not be published. Required fields are marked *