A pluggable JavaScript linter and code transformer with built-in support for JS, TS, JSX, Markdown, YAML, TOML, JSON, and more.
Putout is a pluggable JavaScript linter and code transformer that acts as a drop-in replacement for ESLint. It not only identifies code issues but also performs automated transformations to fix them, supporting a wide range of file types including JavaScript, TypeScript, JSX, Markdown, YAML, TOML, and JSON. It solves the problem of maintaining code quality through declarative, automated refactoring.
JavaScript and TypeScript developers looking to automate code quality improvements, enforce best practices, and modernize codebases across multiple file formats. It's especially useful for teams managing large codebases who need consistent, automated refactoring.
Developers choose Putout over alternatives because it combines linting with powerful, automated code transformations. Unlike ESLint, it can make more drastic changes to code, such as converting CommonJS to ESM or fixing reference errors, all through a simple, plugin-based architecture.
🐊 Pluggable and configurable JavaScript Linter, code transformer and formatter with superpowers 💪: built-in support of js, jsx, ts, markdown, yaml, toml, json and ignore. Write declarative codemods in a simplest possible way 😏
Putout lints and transforms JavaScript, TypeScript, JSX, Markdown, YAML, TOML, JSON, and ignore files, as highlighted in the Key Features, making it versatile for diverse codebases.
Transformations are written with minimal code, such as the 5-line remove-debugger plugin example, simplifying custom rule creation compared to competitors.
It supports ESLint configuration files (.eslintrc.json, eslint.config.js) for seamless integration, acting as a direct substitute with enhanced capabilities.
Includes rules like converting CommonJS to ESM, removing unused variables, and fixing syntax errors, automating refactors that ESLint avoids due to runtime behavior concerns.
Putout makes drastic code changes that could introduce bugs if not reviewed, as the README admits by recommending committing code before using --fix and cautioning about trust issues.
Creating custom plugins requires understanding of abstract syntax trees and Putout's operator system, which is more involved than writing ESLint rules, limiting accessibility for beginners.
While Putout has many built-in plugins, its external plugin community is smaller than ESLint's, reducing the availability of community-driven extensions for niche use cases.
PutOut is an open-source alternative to the following products:
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.