You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

291 lines
8.1 KiB

4 years ago
  1. {
  2. "globals": {
  3. "$": false,
  4. "_": false,
  5. "fuzzy": false,
  6. "jQuery": false,
  7. "moment": false,
  8. "odoo": false,
  9. "openerp": false,
  10. "self": false
  11. },
  12. "env": {
  13. "browser": true
  14. },
  15. "rules": {
  16. "no-alert": "warn",
  17. "no-array-constructor": "warn",
  18. "no-bitwise": "off",
  19. "no-caller": "warn",
  20. "no-case-declarations": "warn",
  21. "no-catch-shadow": "warn",
  22. "no-class-assign": "warn",
  23. "no-cond-assign": "warn",
  24. "no-confusing-arrow": "warn",
  25. "no-console": "off",
  26. "no-const-assign": "warn",
  27. "no-constant-condition": "warn",
  28. "no-continue": "off",
  29. "no-control-regex": "warn",
  30. "no-debugger": "warn",
  31. "no-delete-var": "warn",
  32. "no-div-regex": "warn",
  33. "no-dupe-args": "warn",
  34. "no-dupe-class-members": "warn",
  35. "no-dupe-keys": "warn",
  36. "no-duplicate-case": "warn",
  37. "no-duplicate-imports": "warn",
  38. "no-else-return": "warn",
  39. "no-empty": "warn",
  40. "no-empty-character-class": "warn",
  41. "no-empty-function": "warn",
  42. "no-empty-pattern": "warn",
  43. "no-eq-null": "warn",
  44. "no-eval": "warn",
  45. "no-ex-assign": "warn",
  46. "no-extend-native": "warn",
  47. "no-extra-bind": "warn",
  48. "no-extra-boolean-cast": "warn",
  49. "no-extra-label": "warn",
  50. "no-extra-parens": "warn",
  51. "no-extra-semi": "warn",
  52. "no-fallthrough": "warn",
  53. "no-floating-decimal": "warn",
  54. "no-func-assign": "warn",
  55. "no-implicit-coercion": ["warn", {
  56. "allow": ["~"]
  57. }],
  58. "no-implicit-globals": "warn",
  59. "no-implied-eval": "warn",
  60. "no-inline-comments": "warn",
  61. "no-inner-declarations": "warn",
  62. "no-invalid-regexp": "warn",
  63. "no-invalid-this": "off",
  64. "no-irregular-whitespace": "warn",
  65. "no-iterator": "warn",
  66. "no-label-var": "warn",
  67. "no-labels": "warn",
  68. "no-lone-blocks": "warn",
  69. "no-lonely-if": "warn",
  70. "no-loop-func": "off",
  71. "no-magic-numbers": "off",
  72. "no-mixed-operators": "warn",
  73. "no-mixed-requires": "warn",
  74. "no-mixed-spaces-and-tabs": "warn",
  75. "no-multi-spaces": "warn",
  76. "no-multi-str": "warn",
  77. "no-multiple-empty-lines": "warn",
  78. "no-native-reassign": "warn",
  79. "no-negated-condition": "warn",
  80. "no-negated-in-lhs": "warn",
  81. "no-nested-ternary": "off",
  82. "no-new": "warn",
  83. "no-new-func": "warn",
  84. "no-new-object": "warn",
  85. "no-new-require": "warn",
  86. "no-new-symbol": "warn",
  87. "no-new-wrappers": "warn",
  88. "no-obj-calls": "warn",
  89. "no-octal": "warn",
  90. "no-octal-escape": "warn",
  91. "no-param-reassign": "warn",
  92. "no-path-concat": "warn",
  93. "no-plusplus": "off",
  94. "no-process-env": "warn",
  95. "no-process-exit": "warn",
  96. "no-proto": "warn",
  97. "no-prototype-builtins": "warn",
  98. "no-redeclare": "warn",
  99. "no-regex-spaces": "warn",
  100. "no-restricted-globals": "warn",
  101. "no-restricted-imports": "warn",
  102. "no-restricted-modules": "warn",
  103. "no-restricted-syntax": "warn",
  104. "no-return-assign": "warn",
  105. "no-script-url": "warn",
  106. "no-self-assign": "warn",
  107. "no-self-compare": "warn",
  108. "no-sequences": "warn",
  109. "no-shadow": "warn",
  110. "no-shadow-restricted-names": "warn",
  111. "no-whitespace-before-property": "warn",
  112. "no-spaced-func": "warn",
  113. "no-sparse-arrays": "warn",
  114. "no-sync": "warn",
  115. "no-tabs": "warn",
  116. "no-ternary": "off",
  117. "no-trailing-spaces": "warn",
  118. "no-this-before-super": "warn",
  119. "no-throw-literal": "warn",
  120. "no-undef": "warn",
  121. "no-undef-init": "warn",
  122. "no-undefined": "off",
  123. "no-unexpected-multiline": "warn",
  124. "no-underscore-dangle": "off",
  125. "no-unmodified-loop-condition": "warn",
  126. "no-unneeded-ternary": "warn",
  127. "no-unreachable": "warn",
  128. "no-unsafe-finally": "warn",
  129. "no-unused-expressions": "warn",
  130. "no-unused-labels": "warn",
  131. "no-unused-vars": "warn",
  132. "no-use-before-define": "warn",
  133. "no-useless-call": "warn",
  134. "no-useless-computed-key": "warn",
  135. "no-useless-concat": "warn",
  136. "no-useless-constructor": "warn",
  137. "no-useless-escape": "warn",
  138. "no-useless-rename": "warn",
  139. "no-void": "warn",
  140. "no-var": "off",
  141. "no-warning-comments": "off",
  142. "no-with": "warn",
  143. "array-bracket-spacing": "off",
  144. "array-callback-return": "warn",
  145. "arrow-body-style": "warn",
  146. "arrow-parens": "warn",
  147. "arrow-spacing": "off",
  148. "accessor-pairs": "warn",
  149. "block-scoped-var": "off",
  150. "block-spacing": ["warn", "always"],
  151. "brace-style": "warn",
  152. "callback-return": "warn",
  153. "camelcase": "off",
  154. "capitalized-comments": ["warn", "always", {
  155. "ignoreConsecutiveComments": true,
  156. "ignoreInlineComments": true
  157. }],
  158. "comma-dangle": ["warn", "always-multiline"],
  159. "comma-spacing": ["warn", {
  160. "before": false,
  161. "after": true
  162. }],
  163. "comma-style": "warn",
  164. "complexity": [
  165. "warn",
  166. 15
  167. ],
  168. "computed-property-spacing": "off",
  169. "consistent-return": "off",
  170. "consistent-this": "off",
  171. "constructor-super": "warn",
  172. "curly": "warn",
  173. "default-case": "off",
  174. "dot-location": ["warn", "property"],
  175. "dot-notation": "warn",
  176. "eol-last": "warn",
  177. "eqeqeq": "warn",
  178. "func-names": "off",
  179. "func-style": "off",
  180. "generator-star-spacing": "off",
  181. "global-require": "warn",
  182. "guard-for-in": "off",
  183. "handle-callback-err": "warn",
  184. "id-blacklist": "warn",
  185. "id-length": "off",
  186. "id-match": "warn",
  187. "indent": "warn",
  188. "init-declarations": "warn",
  189. "jsx-quotes": "warn",
  190. "key-spacing": "off",
  191. "keyword-spacing": "warn",
  192. "linebreak-style": [
  193. "warn",
  194. "unix"
  195. ],
  196. "lines-around-comment": "warn",
  197. "max-depth": "warn",
  198. "max-len": ["warn", {
  199. "code": 88,
  200. "ignorePattern": "odoo\\.define\\(",
  201. "tabWidth": 4
  202. }],
  203. "max-lines": "off",
  204. "max-nested-callbacks": "warn",
  205. "max-params": "off",
  206. "max-statements": "off",
  207. "max-statements-per-line": "warn",
  208. "multiline-ternary": "off",
  209. "new-cap": "off",
  210. "new-parens": "warn",
  211. "newline-after-var": "off",
  212. "newline-before-return": "off",
  213. "newline-per-chained-call": "off",
  214. "object-curly-newline": ["warn", { "consistent": true }],
  215. "object-curly-spacing": ["warn", "never"],
  216. "object-property-newline": ["warn", {
  217. "allowAllPropertiesOnSameLine": true
  218. }],
  219. "object-shorthand": "off",
  220. "one-var": "off",
  221. "one-var-declaration-per-line": "off",
  222. "operator-assignment": "warn",
  223. "operator-linebreak": "warn",
  224. "padded-blocks": "off",
  225. "prefer-arrow-callback": "off",
  226. "prefer-const": "warn",
  227. "prefer-reflect": "off",
  228. "prefer-rest-params": "off",
  229. "prefer-spread": "off",
  230. "prefer-template": "off",
  231. "quote-props": "off",
  232. "quotes": "off",
  233. "radix": "warn",
  234. "require-yield": "warn",
  235. "rest-spread-spacing": "off",
  236. "semi": [
  237. "warn",
  238. "always"
  239. ],
  240. "semi-spacing": "warn",
  241. "sort-imports": "warn",
  242. "sort-vars": "off",
  243. "space-before-blocks": "warn",
  244. "space-before-function-paren": "warn",
  245. "space-in-parens": "off",
  246. "space-infix-ops": "off",
  247. "space-unary-ops": "off",
  248. "spaced-comment": ["warn", "always"],
  249. "strict": ["warn", "function"],
  250. "template-curly-spacing": "off",
  251. "unicode-bom": "warn",
  252. "use-isnan": "warn",
  253. "valid-jsdoc": ["warn", {
  254. "prefer": {
  255. "arg": "param",
  256. "argument": "param",
  257. "augments": "extends",
  258. "constructor": "class",
  259. "exception": "throws",
  260. "func": "function",
  261. "method": "function",
  262. "prop": "property",
  263. "return": "returns",
  264. "virtual": "abstract",
  265. "yield": "yields"
  266. },
  267. "preferType": {
  268. "array": "Array",
  269. "bool": "Boolean",
  270. "boolean": "Boolean",
  271. "number": "Number",
  272. "object": "Object",
  273. "str": "String",
  274. "string": "String"
  275. },
  276. "requireParamDescription": false,
  277. "requireReturn": false,
  278. "requireReturnDescription": false,
  279. "requireReturnType": false
  280. }],
  281. "valid-typeof": "warn",
  282. "vars-on-top": "off",
  283. "wrap-iife": "warn",
  284. "wrap-regex": "warn",
  285. "yield-star-spacing": "off",
  286. "yoda": "warn"
  287. },
  288. "parserOptions": {
  289. "ecmaVersion": 2017
  290. }
  291. }