.eslintrc.yml
author Frank Bessou <frank.bessou@logilab.fr>
Mon, 18 Dec 2017 16:10:33 +0100
changeset 255 ba56a53b0abd
parent 236 9e5eb5c240ca
permissions -rw-r--r--
Stringify JSON value before rendering in AttributeValue When a JSON value can't be rendered using React components, its raw value is used. That makes the application crash when the value is an object. In this changeset, we ensure that the displayed value is always a string.

extends:
  - eslint:recommended
  - plugin:react/recommended
parserOptions:
  sourceType: "module"
  ecmaFeatures:
    jsx: true
    arrowFunctions: true
    blockBindings: true
    defaultParams: true
    destructuring: true
    forOf: true
    generators: true
    modules: true
    spread: true
    templateStrings: true
env:
  browser: true
  es6: true
  node: true
  mocha: true
rules:
  arrow-spacing: ["error"]
  comma-dangle: ["error", "always-multiline"]
  comma-spacing: ["error"]
  eqeqeq: [1]
  import/first: "error"
  import/newline-after-import: "error"
  indent: ["error", 4, {"VariableDeclarator": 1, 'SwitchCase': 1}]
  key-spacing: ["error"]
  mocha/no-exclusive-tests: ["error"]
  new-cap: [0]
  no-console: ["error", {"allow": ["warn", "error"]}]
  no-multiple-empty-lines: ["error", {"max":1, "maxEOF": 0, "maxBOF": 0}]
  no-multi-spaces: ["error"]
  no-sequences: "error"
  no-shadow: [0]
  no-trailing-spaces: [2]
  no-unused-vars: ["error", {"argsIgnorePattern": "_$"}]
  no-use-before-define: [2, "nofunc"]
  no-var: "error"
  object-curly-spacing: ["error", "never"]
  object-shorthand: off
  prefer-const: "error"
  quotes: [0]
  react/jsx-indent-props: [2, 4]
  react/no-multi-comp: off
  semi: ["error", "always"]
  space-before-blocks: ["error", "always"]
  space-infix-ops: ["error"]
  space-before-function-paren: ["error", "never"]
plugins:
  - react
  - import
  - mocha