eslint-plugin-split-classnames
v0.3.0
Published
Eslint plugin to keep className attributes short and readable
Downloads
63
Readme
Installation
Install the plugin with
npm i -D eslint-plugin-split-classnames
Eslint config
Add the following code into your .eslintrc.json
config
{
"plugins": ["split-classnames"],
"rules": {
"split-classnames/split-classnames": [
"error",
{
"maxClassNameCharacters": 60,
"functionName": "classNames"
}
]
}
}
To automatically split classnames run the following command or use the Vscode ESlint extension with Ctrl - Shift - P
and Eslint - Fix all auto fixable problems
eslint --fix .