Skip to content

Commit fc32623

Browse files
committed
Replace eslint-plugin-flow-vars with eslint-plugin-flowtype
This is the one people are converging on, and flow-vars may get deprecated.
1 parent 9dab871 commit fc32623

File tree

3 files changed

+7
-6
lines changed

3 files changed

+7
-6
lines changed

config/eslint.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ module.exports = {
2222
parser: 'babel-eslint',
2323

2424
// import plugin is termporarily disabled, scroll below to see why
25-
plugins: [/*'import', */'flow-vars', 'jsx-a11y', 'react'],
25+
plugins: [/*'import', */'flowtype', 'jsx-a11y', 'react'],
2626

2727
env: {
2828
browser: true,
@@ -197,8 +197,9 @@ module.exports = {
197197
'jsx-a11y/img-redundant-alt': 'warn',
198198
'jsx-a11y/no-access-key': 'warn',
199199

200-
// https://github.com/zertosh/eslint-plugin-flow-vars
201-
'flow-vars/define-flow-type': 'warn',
202-
'flow-vars/use-flow-type': 'warn'
200+
// https://github.com/gajus/eslint-plugin-flowtype
201+
'flowtype/define-flow-type': 'warn',
202+
'flowtype/require-valid-file-annotation': 'warn',
203+
'flowtype/use-flow-type': 'warn'
203204
}
204205
};

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"detect-port": "0.1.4",
4747
"eslint": "3.1.1",
4848
"eslint-loader": "1.4.1",
49-
"eslint-plugin-flow-vars": "0.5.0",
49+
"eslint-plugin-flowtype": "2.4.0",
5050
"eslint-plugin-import": "1.12.0",
5151
"eslint-plugin-jsx-a11y": "2.0.1",
5252
"eslint-plugin-react": "5.2.2",

template/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ If you don’t need ESLint integration with your editor, you can safely delete t
257257
Finally, you will need to install some packages *globally*:
258258

259259
```sh
260-
npm install -g eslint babel-eslint eslint-plugin-react eslint-plugin-import eslint-plugin-jsx-a11y eslint-plugin-flow-vars
260+
npm install -g eslint babel-eslint eslint-plugin-react eslint-plugin-import eslint-plugin-jsx-a11y eslint-plugin-flowtype
261261
```
262262

263263
We recognize that this is suboptimal, but it is currently required due to the way we hide the ESLint dependency. The ESLint team is already [working on a solution to this](https://github.com/eslint/eslint/issues/3458) so this may become unnecessary in a couple of months.

0 commit comments

Comments
 (0)