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

@aminya/eslint-plugin-only-warn

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aminya/eslint-plugin-only-warn

Downgrade errors to warnings with flexibility

  • 1.2.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.3K
increased by55.62%
Maintainers
1
Weekly downloads
 
Created
Source

@aminya/eslint-plugin-only-warn

Build Status

Downgrade errors to warnings with flexibility. This fork has more features than the original plugin:

  • exclude-id option: a regex pattern to exclude some of the plugins or rules
  • fatal-as-warning option: an option to make fatal errors a warning

Installation

npm install eslint-plugin-only-warn@npm:@aminya/eslint-plugin-only-warn --save-dev

or in package.json:

"devDependencies": {
    "eslint-plugin-only-warn": "npm:@aminya/eslint-plugin-only-warn@^1.2.1",
}

Note: If you installed ESLint globally (using the -g flag) then you must also use -g for the above command.

Usage

Add only-warn to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:

{
    "plugins": [
        "only-warn"
    ]
}

Settings

exclude-id

You can provide a regex string to exclude some of the rule IDs (a full rule name or the plugin name). You can separate each pattern by |.

{
    "plugins": [
        "only-warn"
    ],
    "settings": {
        "only-warn": {
            "exclude-id": "no-unused-vars|@typescript-eslint"
        }
    }
}

fatal-as-warning

Downgrade fatal errors to warning if 'fatal-as-warning' is enabled in the settings. However, it is recommended that you don't enable this. It is false by default.

{
    "plugins": [
        "only-warn"
    ],
    "settings": {
        "only-warn": {
            "fatal-as-warning": true
        }
    }
}

Keywords

FAQs

Package last updated on 22 May 2021

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc