Skip to content

Latest commit

Β 

History

History
83 lines (56 loc) Β· 1.22 KB

File metadata and controls

83 lines (56 loc) Β· 1.22 KB

@creowis/pretty-code

Opinionated Prettier initializer for modern JavaScript projects. Supports Node.js, React, Next.js, TypeScript, HTML, CSS and Tailwind.


✨ Features

  • Clean, sensible Prettier defaults
  • Automatic import sorting
  • Tailwind class sorting
  • Node & Next.js presets
  • Detects npm / yarn / pnpm automatically
  • Creates prettier.config.js
  • Creates .prettierignore
  • Adds format and format:check scripts
  • Optional instant project formatting
  • Zero manual config writing

πŸš€ Quick Start

npx @creowis/pretty-code next

or

npx @creowis/pretty-code node

πŸ“¦ What Happens Automatically

The CLI will:

  1. Install Prettier and required plugins
  2. Create prettier.config.js (if not exists)
  3. Create .prettierignore (if not exists)
  4. Inject formatting scripts into package.json
  5. Ask if you want to format the project immediately

πŸ“‚ Available Presets

Base

npx @creowis/pretty-code base

Node

npx @creowis/pretty-code node

Next.js

npx @creowis/pretty-code next

πŸ§ͺ Formatting Commands

npm run format
npm run format:check
npx prettier --write <file>

πŸ“„ License

MIT