blob: 97151f2c31490f963c32ce7410d67a8e401a1100 [file] [log] [blame]
Kasper Nilsson4a03e362017-04-27 10:01:37 +02001{
2 "extends": ["eslint:recommended", "google"],
Viktar Donich211f0532018-08-14 10:59:10 -07003 "parserOptions": {
4 "ecmaVersion": 8
5 },
Kasper Nilsson4a03e362017-04-27 10:01:37 +02006 "env": {
7 "browser": true,
8 "es6": true
9 },
10 "globals": {
11 "__dirname": false,
12 "app": false,
13 "page": false,
14 "Polymer": false,
15 "process": false,
16 "require": false,
17 "Gerrit": false,
18 "Promise": false,
19 "assert": false,
20 "test": false,
21 "flushAsynchronousOperations": false
22 },
23 "rules": {
24 "arrow-parens": ["error", "as-needed"],
Kasper Nilssonac8bea92017-07-20 13:07:48 -070025 "block-spacing": ["error", "always"],
Kasper Nilsson4a03e362017-04-27 10:01:37 +020026 "brace-style": ["error", "1tbs", { "allowSingleLine": true }],
27 "camelcase": "off",
28 "comma-dangle": ["error", "always-multiline"],
29 "eol-last": "off",
Kasper Nilsson076adcd2017-07-05 11:17:26 -070030 "indent": "off",
31 "indent-legacy": ["error", 2, {
Kasper Nilsson4a03e362017-04-27 10:01:37 +020032 "MemberExpression": 2,
33 "FunctionDeclaration": {"body": 1, "parameters": 2},
34 "FunctionExpression": {"body": 1, "parameters": 2},
35 "CallExpression": {"arguments": 2},
36 "ArrayExpression": 1,
37 "ObjectExpression": 1,
38 "SwitchCase": 1
39 }],
Kasper Nilsson1b5d74b2017-06-02 11:12:50 -070040 "keyword-spacing": ["error", { "after": true, "before": true }],
Kasper Nilsson4a03e362017-04-27 10:01:37 +020041 "max-len": [
42 "error",
43 80,
44 2,
45 {"ignoreComments": true}
46 ],
47 "new-cap": ["error", { "capIsNewExceptions": ["Polymer"] }],
48 "no-console": "off",
Kasper Nilsson0c045622017-08-18 15:53:43 -070049 "no-restricted-syntax": [
50 "error",
51 {
52 "selector": "ExpressionStatement > CallExpression > MemberExpression[object.name='test'][property.name='only']",
53 "message": "Remove test.only."
54 },
55 {
56 "selector": "ExpressionStatement > CallExpression > MemberExpression[object.name='suite'][property.name='only']",
57 "message": "Remove suite.only."
58 }
59 ],
Kasper Nilsson4a03e362017-04-27 10:01:37 +020060 "no-undef": "off",
Kasper Nilsson076adcd2017-07-05 11:17:26 -070061 "no-useless-escape": "off",
Kasper Nilsson4a03e362017-04-27 10:01:37 +020062 "no-var": "error",
63 "object-shorthand": ["error", "always"],
64 "prefer-arrow-callback": "error",
65 "prefer-const": "error",
66 "prefer-spread": "error",
Kasper Nilsson4a03e362017-04-27 10:01:37 +020067 "quote-props": ["error", "consistent-as-needed"],
68 "require-jsdoc": "off",
69 "semi": [2, "always"],
70 "template-curly-spacing": "error",
71 "valid-jsdoc": "off"
72 },
73 "plugins": [
74 "html"
Kasper Nilssone71334e2017-05-25 15:20:09 -070075 ],
76 "settings": {
77 "html/report-bad-indent": "error"
78 }
Kasper Nilsson4a03e362017-04-27 10:01:37 +020079}