eslint-plugin-zxlint

0.6.1 • Public • Published

eslint-plugin-zxlint

not import and require some modules

Installation

You'll first need to install ESLint:

$ npm i eslint --save-dev

Next, install eslint-plugin-zxlint: 先安装esLint

$ npm install eslint-plugin-zxlint --save-dev

Usage

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

{
    "plugins": [
        "zxlint"
    ]
}

Then configure the rules you want to use under the rules section.

{
    "rules": {
        "zxlint/rule-name": 2
    }
}
{
    "rules": {
        "zxlint/no-import": ['error',{'files':['a.js','b.js'],'modules':['fs','http','events','os']}]
    }
}
files receive a Array, modules too    
a.js,b.js can import fs http events os modules, others can not

Supported Rules

  • Fill in provided rules here

Package Sidebar

Install

npm i eslint-plugin-zxlint

Weekly Downloads

1

Version

0.6.1

License

ISC

Unpacked Size

8.54 kB

Total Files

9

Last publish

Collaborators

  • zhouxin98