Skip to content

Commit

Permalink
Adds no-redeclare to our rules
Browse files Browse the repository at this point in the history
When we deployed the app, a bug I introduced in segmentio/app#e3fa8a1886cb17e8a3765d70c215b42591729c0d prevented the page from loading for all users. We needed to rollback, and I introduced a fix segmentio/app#7fb59a0602d55d8095c249d583fab6ddd75a975d that has fixed the issue.

The problem was that I accidentally created a conflicting variable in the global scope for that module. (`var` up top, `function` way later) By adding `no-redeclare`, this will catch that same problem in the future. As noted in eslint/eslint#2953, this has already been fixed in `master`, so now we just await a new release. In the meantime, adding this rule will still be a good idea as it will catch other similar problems.
  • Loading branch information
dominicbarnes committed Jul 9, 2015
1 parent 911a557 commit 580606e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ module.exports = {
'no-multiple-empty-lines': [2, {'max': 2}],
'no-nested-ternary': 2,
'no-new-require': 2,
'no-redeclare': 2,
'no-self-compare': 2,
'no-shadow': 0,
'no-throw-literal': 2,
Expand Down

0 comments on commit 580606e

Please sign in to comment.