0.0.1 ā€¢ Published 2 years ago

prettyvue v0.0.1

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

prettyvue

Runs Prettyhtml on your changed (based on Git) files.

Example:

prettyvue
šŸ”  Finding changed files since git revision 2eb4337.
šŸŽÆ  Found 1 changed file.
    ā˜  printWidth: 80, tabWidth: 2
āœļø  Fixing up test.html.
āœ…  Everything is awesome!

Install

npm install --save-dev prettyvue

Usage

With npx: (No install required)

npx prettyvue

Pre-Commit Hook

You can run prettyvue as a pre-commit hook using husky.

yarn add --dev husky

In package.json's "scripts" section, add:

"precommit": "prettyvue"

CLI Flags

-s --staged

Only staged files will be formatted, and they will be re-staged after formatting.

Formatter options

We use prettier resolveConfig to indentify your tabWidth and printWidth. It will fallback to .editorconfig.