Skip to content
Solves the problem of false positives with `no-undef` and `no-unused-vars` when using babel-eslint
JavaScript
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
test fix use-flow-type when type is used before defined Jul 25, 2016
.eslintrc
.gitignore
.travis.yml
README.md deprecation notice Aug 4, 2016
define-flow-type.js handle TypeParameterDeclaration in define-flow-type May 1, 2016
index.js disable rules by defaults Nov 28, 2015
package.json 0.5.0 Jul 25, 2016
use-flow-type.js fix use-flow-type when type is used before defined Jul 25, 2016

README.md

THIS PROJECT IS DEPRECATED

The functionality provided by eslint-plugin-flow-vars has been merge into eslint-plugin-flowtype.

To migrate, install eslint-plugin-flowtype@2.4.0 or higher, and update your eslint config like this:

{
  "parser": "babel-eslint",
  "plugins": [
-    "flow-vars"
+    "flowtype"
  ],
  "rules": {
-    "flow-vars/define-flow-type": 1,
-    "flow-vars/use-flow-type": 1
+    "flowtype/define-flow-type": 1,
+    "flowtype/use-flow-type": 1
  }
}

eslint-plugin-flow-vars

Build Status

An eslint plugin that makes flow type annotations global variables and marks declarations as used. Solves the problem of false positives with no-undef and no-unused-vars when using babel-eslint.

Usage

npm install eslint babel-eslint eslint-plugin-flow-vars

In your .eslintrc:

{
  "parser": "babel-eslint",
  "plugins": [
    "flow-vars"
  ],
  "rules": {
    "flow-vars/define-flow-type": 1,
    "flow-vars/use-flow-type": 1
  }
}
You can’t perform that action at this time.