eslint-config-mongodb-js
Advanced tools
Comparing version
{ | ||
"name": "eslint-config-mongodb-js", | ||
"description": "eslint sharable configs for mongodb-js.", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"author": "Lucas Hrabovsky <lucas@mongodb.com> (http://imlucas.com)", | ||
@@ -25,5 +25,5 @@ "homepage": "http://github.com/mongodb-js/eslint-config", | ||
"devDependencies": { | ||
"babel-eslint": "^5.0.0", | ||
"eslint": "^2.3.0", | ||
"eslint-plugin-react": "^4.2.0", | ||
"babel-eslint": "^6.0.0", | ||
"eslint": "^2.5.3", | ||
"eslint-plugin-react": "^5.2.2", | ||
"mocha": "^2.3.4", | ||
@@ -30,0 +30,0 @@ "mongodb-js-fmt": "0.0.3", |
@@ -40,3 +40,3 @@ /** | ||
// Prevent usage of setState in componentDidMount | ||
'react/no-did-mount-set-state': [2, 'allow-in-func'], | ||
'react/no-did-mount-set-state': 2, | ||
// Prevent usage of setState in componentDidUpdate | ||
@@ -55,3 +55,5 @@ 'react/no-did-update-set-state': 2, | ||
// Prevent extra closing tags for components without children | ||
'react/self-closing-comp': 2, | ||
'react/self-closing-comp': [2, { | ||
component: true | ||
}], | ||
// Enforce component methods order | ||
@@ -58,0 +60,0 @@ 'react/sort-comp': [2, { |
@@ -48,3 +48,3 @@ var config = require('./config'); | ||
// disallow use of labels for anything other then loops and switches | ||
'no-empty-label': ERROR, | ||
'no-labels': ERROR, | ||
// disallow comparisons to null without a type-checking operator | ||
@@ -51,0 +51,0 @@ 'no-eq-null': IGNORE, |
@@ -61,2 +61,12 @@ var config = require('./config'); | ||
}], | ||
// require a space after return, throw, and case | ||
'keyword-spacing': [2, { | ||
before: true, | ||
after: true, | ||
overrides: { | ||
return: { after: true }, | ||
throw: { after: true }, | ||
case: { after: true } | ||
} | ||
}], | ||
// enforces empty lines around comments | ||
@@ -131,4 +141,2 @@ 'lines-around-comment': IGNORE, | ||
'sort-vars': IGNORE, | ||
// require a space after certain keywords | ||
'space-after-keywords': ERROR, | ||
// require or disallow space before blocks | ||
@@ -142,4 +150,2 @@ 'space-before-blocks': ERROR, | ||
'space-infix-ops': ERROR, | ||
// require a space after return, throw, and case | ||
'space-return-throw-case': ERROR, | ||
// Require or disallow spaces before/after unary operators | ||
@@ -146,0 +152,0 @@ 'space-unary-ops': IGNORE, |
38326
0.23%710
1.14%