0.1.8 • Published 3 years ago

eslint-plugin-weavers-react v0.1.8

Weekly downloads
37
License
ISC
Repository
bitbucket
Last release
3 years ago

ESLint-Custom-Rules


The repository is a collection of custom eslint-rules used to maintain code-quality.

Install

From your terminal type

    npm install --save-dev eslint-plugin-weavers-react

to install the plugin as a devDependency

Configure

On your eslintrc file, esure that the options are set as shown below.

{
    "plugins" : ["react","weavers-react"]
}

How to Use

The plugin features the following rules.

1. react_maxlines_per_function

The rule to limit the number of lines inside a function in react.

"weavers-react/react_maxlines_per_function" : [
    "error",
    {"maxLines": 80, "maxJSLines": 30, "maxJSXLines": 50}
]
  • maxLines : refer to the maximum allowed lines in a function.

  • maxJSXLines : refer to the maximum allowed lines in the functin that can have a JSX Element.

  • maxJSLines: refer to the maximum allowed lines without any JSXElements.

Dependencies

Package works best with: eslint : >=7.5.0 @babel/eslint-parser : **>=7.13.10"

0.1.8

3 years ago

0.1.7

3 years ago

0.1.6

4 years ago

0.1.5

4 years ago

0.1.4

4 years ago

0.1.3

4 years ago

0.1.2

4 years ago

0.1.1

4 years ago

0.1.0

4 years ago