Skip to content

Commit

Permalink
Merge pull request #96 from box/issue90
Browse files Browse the repository at this point in the history
Build: Upgrade ESLint (fixes #90)
  • Loading branch information
nzakas committed Aug 11, 2015
2 parents d4fa816 + ec06bed commit 6412852
Show file tree
Hide file tree
Showing 4 changed files with 70 additions and 14 deletions.
70 changes: 63 additions & 7 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,80 @@
"leche": false,
"$": false
},
"extends": "eslint:recommended",
"rules": {
"no-alert": 2,
"no-array-constructor": 2,
"no-caller": 2,
"no-catch-shadow": 2,
"no-empty-label": 2,
"no-eval": 2,
"no-extend-native": 2,
"no-extra-bind": 2,
"no-extra-parens": [2, "functions"],
"no-floating-decimal": 2,
"no-implied-eval": 2,
"no-iterator": 2,
"no-label-var": 2,
"no-labels": 2,
"no-lone-blocks": 2,
"no-loop-func": 2,
"no-multi-spaces": 2,
"no-multi-str": 2,
"no-native-reassign": 2,
"no-nested-ternary": 2,
"no-new": 2,
"no-new-func": 2,
"no-new-object": 2,
"no-new-wrappers": 2,
"no-octal-escape": 2,
"no-process-exit": 2,
"no-proto": 2,
"no-return-assign": 2,
"no-script-url": 2,
"no-sequences": 2,
"no-shadow": 2,
"no-shadow-restricted-names": 2,
"no-spaced-func": 2,
"no-trailing-spaces": 2,
"no-undef-init": 2,
"no-underscore-dangle": 0,
"no-unused-expressions": 2,

// We allow unused args
"no-unused-vars": [2, {"args": "none"}],
"no-use-before-define": 2,
"no-with": 2,

"brace-style": 2,
"camelcase": 2,
"comma-spacing": 2,
"consistent-return": 2,
"curly": [2, "all"],
"dot-notation": [2, { "allowKeywords": true }],
"eol-last": 2,
"eqeqeq": 2,
"func-style": [2, "declaration"],
"strict": [2, "function"],
"guard-for-in": 2,
"no-floating-decimal": 2,
"no-underscore-dangle": 0,
"no-nested-ternary": 2,
"indent": [2, "tab"],
"key-spacing": [2, { "beforeColon": false, "afterColon": true }],
"new-cap": 2,
"new-parens": 2,
"quotes": [2, "single"],
"radix": 2,
"wrap-iife": 2,
"semi": 2,
"semi-spacing": [2, {"before": false, "after": true}],
"space-after-keywords": 2,
"space-infix-ops": 2,
"space-return-throw-case": 2,
"space-unary-ops": [2, { "words": true, "nonwords": false }],
"strict": [2, "function"],
"wrap-iife": 2,
"valid-jsdoc": [2, {
"prefer": {
"return": "returns"
}
}],
// We allow unused args
"no-unused-vars": [2, {"args": "none"}]
"yoda": [2, "never"]
}
}
6 changes: 3 additions & 3 deletions lib/dom-jquery.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
*/

Box.JQueryDOM = (function() {
'use strict';
'use strict';

return {
return {

type: 'jquery',

Expand Down Expand Up @@ -59,7 +59,7 @@ Box.JQueryDOM = (function() {
off: function(element, type, listener) {
$(element).off(type, listener);
}
};
};
}());

Box.DOM = Box.JQueryDOM;
6 changes: 3 additions & 3 deletions lib/dom-native.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@


Box.NativeDOM = (function(){
'use strict';
'use strict';

return {
return {

type: 'native',

Expand Down Expand Up @@ -59,7 +59,7 @@ Box.NativeDOM = (function(){
off: function(element, type, listener) {
element.removeEventListener(type, listener, false);
}
};
};
}());

Box.DOM = Box.NativeDOM;
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"devDependencies": {
"assertive-chai": "^1.0.2",
"dateformat": "^1.0.11",
"eslint": "^0.18.0",
"eslint": "^1.1.0",
"jquery": "^1.11.1",
"karma": "^0.12.31",
"karma-coverage": "^0.2.7",
Expand Down

0 comments on commit 6412852

Please sign in to comment.