Skip to content

How to automatically run Prettier on all files in a project

FULL-STACK WEB DEVELOPMENT BOOTCAMP

2024 COHORT SIGNUPS END TOMORROW

Create a .prettierrc file in your project, for example

{
  "tabWidth": 2,
  "useTabs": false,
  "semi": false
}

Then run

npx prettier -w .
  • Learn modern web development in my BOOTCAMP (SIGNUP END TOMORROW FEB 20, 2024)
  • THE VALLEY OF CODE (+ PRO), your web development manual
  • I wrote 15+ coding BOOKS, all available in THE VALLEY OF CODE PRO
  • Indie solopreneur internet business masterclass SOLO LAB (summer 2024)