Skip to content

Commit

Permalink
feat: added eslint-plugin-react-hooks fixes #25
Browse files Browse the repository at this point in the history
  • Loading branch information
GoPro16 committed Feb 23, 2019
1 parent f8b5b57 commit a16bdcf
Show file tree
Hide file tree
Showing 4 changed files with 200 additions and 387 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ npm install eslint-config-availity --save-dev
- [eslint-plugin-jest](https://github.com/jest-community/eslint-plugin-jest)
- [eslint-plugin-promise](https://github.com/xjamundx/eslint-plugin-promise)
- [eslint-plugin-unicorn](https://github.com/sindresorhus/eslint-plugin-unicorn)
- [eslint-plugin-react-hooks](https://github.com/facebook/react/tree/master/packages/eslint-plugin-react-hooks)

## Usage

Expand Down
6 changes: 4 additions & 2 deletions browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ module.exports = {
'plugin:jest/recommended',
'prettier',
'prettier/react',
'plugin:unicorn/recommended',
'plugin:unicorn/recommended'
],

plugins: ['promise', 'jest', 'promise', 'unicorn'],
plugins: ['promise', 'jest', 'promise', 'unicorn','react-hooks'],
parser: 'babel-eslint',

parserOptions: {
Expand All @@ -32,6 +32,8 @@ module.exports = {
'react/sort-comp': 0,
'react/jsx-filename-extension': [1, { extensions: ['.js', '.jsx'] }],
'react/require-default-props': 0,
'react-hooks/rules-of-hooks': 'warn',
'react-hooks/exhaustive-deps': 'warn',
'react/forbid-prop-types': [
'error',
{
Expand Down
Loading

0 comments on commit a16bdcf

Please sign in to comment.