0.0.15 • Published 3 years ago
eslint-plugin-react-soc v0.0.15
eslint-plugin-react-soc
An eslint plugin that ensures separation of business logic from presentation logic in React functional components.
Installation
You'll first need to install ESLint:
# npm
npm i eslint --save-dev
# yarn
yarn add eslint --devNext, install eslint-plugin-react-soc:
#npm
npm install eslint-plugin-react-soc --save-dev
#yarn
yarn add eslint-plugin-react-soc --devUsage
Add react-soc to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:
{
"plugins": ["react-soc"]
}Then configure the rules you want to use under the rules section.
{
"rules": {
"react-soc/separation-of-concerns": "error"
}
}Rules
| Name | Description |
|---|---|
| separation-of-concerns | rule to warn mixing of business logic with presentation logic |