UNPKG

@beyondessential/eslint-config-js

Version:
52 lines (51 loc) 1.62 kB
module.exports = { extends: ['airbnb', 'plugin:prettier/recommended'], rules: { 'class-methods-use-this': 'off', 'import/order': 'warn', 'import/prefer-default-export': 'off', 'max-classes-per-file': 'off', 'no-await-in-loop': 'off', 'no-continue': 'off', 'no-plusplus': 'off', 'no-prototype-builtins': 'off', 'no-restricted-globals': 'off', 'no-restricted-syntax': [ 'error', { selector: 'ForInStatement', message: 'for..in loops iterate over the entire prototype chain, which is virtually never what you want. Use Object.{keys,values,entries}, and iterate over the resulting array.', }, { selector: 'LabeledStatement', message: 'Labels are a form of GOTO; using them makes code confusing and hard to maintain and understand.', }, { selector: 'WithStatement', message: '`with` is disallowed in strict mode because it makes code impossible to predict and optimize.', }, ], 'no-use-before-define': 'off', 'prettier/prettier': [ 'error', { arrowParens: 'avoid', printWidth: 100, singleQuote: true, trailingComma: 'all' }, ], radix: 'off', 'react/forbid-prop-types': [ 'error', { forbid: ['any'], checkContextTypes: true, checkChildContextTypes: true }, ], 'react/jsx-filename-extension': 'off', 'react/jsx-one-expression-per-line': 'off', 'react/jsx-props-no-spreading': 'off', 'react/no-did-update-set-state': 'off', }, settings: { react: { version: '16.2', }, }, };