Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@pega/prettier-config

pega-cosmos4kSEE LICENSE IN LICENSE0.16.3TypeScript support: included

Pega front-end Prettier configuration.

prettier, prettier config

readme

@pega/prettier-config

Pegasystems front-end Prettier configuration.

Installation

Install Prettier and the Pega config.

npm i -D prettier @pega/prettier-config

Setting up your config

Extend from the Pega configuration in your Prettier configuration file.

"@pega/prettier-config"

Running Prettier

Run Prettier to check, for example, all .json files in the current directory.

prettier -c "./**/*.json"

VS Code integration

You can install the VS Code extension, and update your .vscode/settings.json to enable your editor to run Prettier for you automatically.

{
  "editor.formatOnSave": true
}