npm run format

Category: Node.js & npm/yarn

npm run format

Run the 'format' script to auto-format code with a tool like Prettier

Runs the formatter (usually Prettier) to automatically rewrite your code files to match the configured style rules.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.