Просмотр исходного кода

Merge pull request #1113 from kazupon/upgrade-eslint

upgrade eslint v1.0.0
Evan You 11 лет назад
Родитель
Сommit
ce16e4ef66
4 измененных файлов с 5 добавлено и 41 удалено
  1. 1 19
      .eslintrc
  2. 1 1
      package.json
  3. 1 19
      test/.eslintrc
  4. 2 2
      test/unit/specs/misc_spec.js

+ 1 - 19
.eslintrc

@@ -30,29 +30,21 @@
     "eqeqeq": [2, "allow-null"],
     "func-names": 0,
     "func-style": 0,
-    "generator-star": 0,
     "generator-star-spacing": [2, { "before": true, "after": true }],
-    "global-strict": 0,
     "guard-for-in": 0,
     "handle-callback-err": [2, "^(err|error)$" ],
-    "indent": [2, 2],
+    "indent": [2, 2, { "SwitchCase": 1 }],
     "key-spacing": [2, { "beforeColon": false, "afterColon": true }],
     "linebreak-style": 0,
     "lines-around-comment": 0,
-    "max-depth": 0,
-    "max-len": 0,
     "max-nested-callbacks": 0,
-    "max-params": 0,
-    "max-statements": 0,
     "new-cap": [2, { "newIsCap": true, "capIsNew": false }],
     "new-parens": 2,
     "newline-after-var": 0,
     "no-alert": 0,
     "no-array-constructor": 2,
-    "no-bitwise": 0,
     "no-caller": 2,
     "no-catch-shadow": 0,
-    "no-comma-dangle": 0,
     "no-cond-assign": 2,
     "no-console": 0,
     "no-constant-condition": 0,
@@ -67,7 +59,6 @@
     "no-else-return": 0,
     "no-empty": 0,
     "no-empty-character-class": 2,
-    "no-empty-class": 0,
     "no-empty-label": 2,
     "no-eq-null": 0,
     "no-eval": 2,
@@ -77,7 +68,6 @@
     "no-extra-boolean-cast": 2,
     "no-extra-parens": 0,
     "no-extra-semi": 0,
-    "no-extra-strict": 0,
     "no-fallthrough": 2,
     "no-floating-decimal": 2,
     "no-func-assign": 2,
@@ -110,13 +100,11 @@
     "no-octal-escape": 2,
     "no-param-reassign": 0,
     "no-path-concat": 0,
-    "no-plusplus": 0,
     "no-process-env": 0,
     "no-process-exit": 0,
     "no-proto": 0,
     "no-redeclare": 2,
     "no-regex-spaces": 2,
-    "no-reserved-keys": 0,
     "no-restricted-modules": 0,
     "no-return-assign": 2,
     "no-script-url": 0,
@@ -124,7 +112,6 @@
     "no-sequences": 2,
     "no-shadow": 0,
     "no-shadow-restricted-names": 2,
-    "no-space-before-semi": 0,
     "no-spaced-func": 2,
     "no-sparse-arrays": 2,
     "no-sync": 0,
@@ -146,7 +133,6 @@
     "no-void": 0,
     "no-warning-comments": 0,
     "no-with": 2,
-    "no-wrap-func": 2,
     "object-curly-spacing": 0,
     "object-shorthand": 0,
     "one-var": [2, { "initialized": "never" }],
@@ -160,18 +146,14 @@
     "semi": [2, "never"],
     "semi-spacing": 0,
     "sort-vars": 0,
-    "space-after-function-name": 0,
     "space-after-keywords": [2, "always"],
     "space-before-blocks": [2, "always"],
     "space-before-function-paren": [2, "always"],
-    "space-before-function-parentheses": 0,
-    "space-in-brackets": 0,
     "space-in-parens": [2, "never"],
     "space-infix-ops": 2,
     "space-return-throw-case": 2,
     "space-unary-ops": [2, { "words": true, "nonwords": false }],
     "spaced-comment": [2, "always", { "markers": ["global", "globals", "eslint", "eslint-disable", "*package", "!"] }],
-    "spaced-line-comment": 0,
     "strict": 0,
     "use-isnan": 2,
     "valid-jsdoc": 0,

+ 1 - 1
package.json

@@ -32,7 +32,7 @@
     "casperjs": "^1.1.0-beta3",
     "codecov.io": "^0.1.2",
     "grunt": "^0.4.5",
-    "grunt-eslint": "^16.0.0",
+    "grunt-eslint": "^17.0.0",
     "grunt-karma": "^0.8.3",
     "jasmine-core": "^2.3.4",
     "karma": "^0.12.31",

+ 1 - 19
test/.eslintrc

@@ -40,29 +40,21 @@
     "eqeqeq": [2, "allow-null"],
     "func-names": 0,
     "func-style": 0,
-    "generator-star": 0,
     "generator-star-spacing": [2, { "before": true, "after": true }],
-    "global-strict": 0,
     "guard-for-in": 0,
     "handle-callback-err": [2, "^(err|error)$" ],
-    "indent": [2, 2],
+    "indent": [2, 2, { "SwitchCase": 1 }],
     "key-spacing": [2, { "beforeColon": false, "afterColon": true }],
     "linebreak-style": 0,
     "lines-around-comment": 0,
-    "max-depth": 0,
-    "max-len": 0,
     "max-nested-callbacks": 0,
-    "max-params": 0,
-    "max-statements": 0,
     "new-cap": [2, { "newIsCap": true, "capIsNew": false }],
     "new-parens": 2,
     "newline-after-var": 0,
     "no-alert": 0,
     "no-array-constructor": 2,
-    "no-bitwise": 0,
     "no-caller": 2,
     "no-catch-shadow": 0,
-    "no-comma-dangle": 0,
     "no-cond-assign": 2,
     "no-console": 0,
     "no-constant-condition": 0,
@@ -77,7 +69,6 @@
     "no-else-return": 0,
     "no-empty": 0,
     "no-empty-character-class": 2,
-    "no-empty-class": 0,
     "no-empty-label": 2,
     "no-eq-null": 0,
     "no-eval": 2,
@@ -87,7 +78,6 @@
     "no-extra-boolean-cast": 2,
     "no-extra-parens": 0,
     "no-extra-semi": 0,
-    "no-extra-strict": 0,
     "no-fallthrough": 2,
     "no-floating-decimal": 2,
     "no-func-assign": 2,
@@ -120,13 +110,11 @@
     "no-octal-escape": 2,
     "no-param-reassign": 0,
     "no-path-concat": 0,
-    "no-plusplus": 0,
     "no-process-env": 0,
     "no-process-exit": 0,
     "no-proto": 0,
     "no-redeclare": 2,
     "no-regex-spaces": 2,
-    "no-reserved-keys": 0,
     "no-restricted-modules": 0,
     "no-return-assign": 2,
     "no-script-url": 0,
@@ -134,7 +122,6 @@
     "no-sequences": 2,
     "no-shadow": 0,
     "no-shadow-restricted-names": 2,
-    "no-space-before-semi": 0,
     "no-spaced-func": 2,
     "no-sparse-arrays": 2,
     "no-sync": 0,
@@ -156,7 +143,6 @@
     "no-void": 0,
     "no-warning-comments": 0,
     "no-with": 2,
-    "no-wrap-func": 2,
     "object-curly-spacing": 0,
     "object-shorthand": 0,
     "one-var": [2, { "initialized": "never" }],
@@ -170,18 +156,14 @@
     "semi": [2, "never"],
     "semi-spacing": 0,
     "sort-vars": 0,
-    "space-after-function-name": 0,
     "space-after-keywords": [2, "always"],
     "space-before-blocks": [2, "always"],
     "space-before-function-paren": [2, "always"],
-    "space-before-function-parentheses": 0,
-    "space-in-brackets": 0,
     "space-in-parens": [2, "never"],
     "space-infix-ops": 2,
     "space-return-throw-case": 2,
     "space-unary-ops": [2, { "words": true, "nonwords": false }],
     "spaced-comment": [2, "always", { "markers": ["global", "globals", "eslint", "eslint-disable", "*package", "!"] }],
-    "spaced-line-comment": 0,
     "strict": 0,
     "use-isnan": 2,
     "valid-jsdoc": 0,

+ 2 - 2
test/unit/specs/misc_spec.js

@@ -195,8 +195,8 @@ describe('Misc', function () {
       },
       watch: {
         obj: {
-            handler: spy1,
-            deep: true
+          handler: spy1,
+          deep: true
         },
         arr: spy2,
         // if the watcher is watching the added value,