New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More

@putout/plugin-remove-empty

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@putout/plugin-remove-empty

putout plugin adds ability to find and remove blocks with empty body


Version published
Weekly downloads
12K
decreased by-3.95%
Maintainers
1
Weekly downloads
 
Created

putout-plugin-remove-empty NPM version Dependency Status

putout plugin adds ability to find and remove:

  • empty block statements;
  • empty patterns;
  • empty imports;
  • empty arguments;

Install

npm i @putout/plugin-remove-empty

Rules

{
    "rules": {
        "remove-empty/block": "on",
        "remove-empty/pattern": "on",
        "remove-empty/argument": "on",
        "remove-empty/import": ["on", {
            "ignore": []
        }]
    }
}

❌ Incorrect code example

import "hello";

if (2 > 3) {}

✅ Correct code Example

import hello from "hello";

if (2 > 3) {
    hello();
}

License

MIT

FAQs

Package last updated on 08 Jul 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts