Files
Eventment/.eslintrc.js

82 lines
2.8 KiB
JavaScript

module.exports = {
root: true,
extends: '@react-native-community',
env: {
mocha: true,
browser: true,
},
// parser: 'babel-eslint',
// plugins: ['babel', 'immutablejs'],
plugins: ['immutablejs'],
rules: {
'comma-dangle': 'off',
'func-call-spacing': 'off',
'import/prefer-default-export': 'off',
'max-len': ['error', 150, { ignoreComments: true, ignoreTemplateLiterals: true }],
'no-confusing-arrow': 'off',
'no-mixed-operators': 'off',
'no-restricted-properties': [
2,
{
object: 'describe',
property: 'only',
message:
'Please remove any instance of .only from unit tests. If .only is required outside of a unit test, feel free to add an eslint override to ignore this instance of this error.',
},
{
object: 'it',
property: 'only',
message:
'Please remove any instance of .only from unit tests. If .only is required outside of a unit test, feel free to add an eslint override to ignore this instance of this error.',
},
{
object: 'context',
property: 'only',
message:
'Please remove any instance of .only from unit tests. If .only is required outside of a unit test, feel free to add an eslint override to ignore this instance of this error.',
},
{
object: 'tape',
property: 'only',
message:
'Please remove any instance of .only from unit tests. If .only is required outside of a unit test, feel free to add an eslint override to ignore this instance of this error.',
},
{
object: 'test',
property: 'only',
message:
'Please remove any instance of .only from unit tests. If .only is required outside of a unit test, feel free to add an eslint override to ignore this instance of this error.',
},
{
object: 'fixture',
property: 'only',
message:
'Please remove any instance of .only from unit tests. If .only is required outside of a unit test, feel free to add an eslint override to ignore this instance of this error.',
},
],
'no-spaced-func': 'off',
'react/jsx-closing-bracket-location': 'off',
'react/jsx-first-prop-new-line': 'off',
'react/jsx-no-literals': ['error', { noStrings: true }],
'react/jsx-no-target-blank': 'off',
'react/no-danger': 'off',
'space-before-function-paren': 'off',
indent: 'off',
'indent-legacy': 'off',
'immutablejs/no-native-map-set': 'error',
'no-invalid-this': 'off',
// 'babel/no-invalid-this': 'error',
},
overrides: [
{
files: ['lib/fixtures/**/*.js', '**/testHelper.js'],
rules: {
'import/no-extraneous-dependencies': ['error', { devDependencies: true }],
},
globals: {
expect: false,
},
},
],
};