code-formatter

A simple example skill for demonstration purposes

⭐17stars🔀2forks📁View on GitHub🕐Updated Dec 2, 2025

When & Why to Use This Skill

The Code Formatter skill is an automated utility designed to streamline code maintenance by enforcing consistent styling and linting rules. It leverages industry-standard tools like Prettier and ESLint to automatically format JavaScript, TypeScript, JSON, YAML, and Markdown files, helping developers maintain high-quality, readable codebases with minimal manual effort.

Use Cases

  • Automated Code Cleanup: Quickly format individual files or entire directories to comply with Prettier and ESLint standards, reducing manual editing time.
  • Pre-commit Validation: Run formatting checks as part of a development workflow to ensure code adheres to project style guides before committing changes to version control.
  • Multi-format Standardization: Maintain a professional project structure by standardizing the formatting of configuration files (JSON, YAML) and documentation (Markdown) alongside source code.
namecode-formatter
descriptionYou are a senior code reviewer.
- namereviewer

Code Formatter Skill

Automatically formats code files using industry-standard tools.

Capabilities

  • Format JavaScript/TypeScript with Prettier
  • Fix ESLint issues automatically
  • Format JSON, YAML, and Markdown files
  • Run format checks before commits

Usage Examples

Format a single file:

"Format the src/index.js file"

Format entire directory:

"Format all files in the src/ directory"

Check formatting without changes:

"Check if files in src/ are properly formatted"

Configuration

Set these environment variables for custom configuration:

  • PRETTIER_CONFIG: Path to prettier config (default: .prettierrc)
  • ESLINT_CONFIG: Path to eslint config (default: .eslintrc.js)