Skip to content

Commit

Permalink
Disallow Incorrect Early Use (no-use-before-define)
Browse files Browse the repository at this point in the history
Using hoisting is still allowed, but it is prevented when clearly
incorrect, e.g.:

console.log(foo)
var foo = 1

var variable1 = variable1

Fixes: standard/standard#615
Fixes: standard/standard#636
  • Loading branch information
feross committed Feb 9, 2017
1 parent f71b732 commit a40f65a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions eslintrc.json
Expand Up @@ -129,6 +129,7 @@
"no-unsafe-negation": "error",
"no-unused-expressions": ["error", { "allowShortCircuit": true, "allowTernary": true }],
"no-unused-vars": ["error", { "vars": "all", "args": "none" }],
"no-use-before-define": ["error", { "functions": false, "classes": false, "variables": false }],
"no-useless-call": "error",
"no-useless-computed-key": "error",
"no-useless-constructor": "error",
Expand Down

0 comments on commit a40f65a

Please sign in to comment.