mnml/client/.eslintrc.js
2018-10-25 00:04:48 +11:00

47 lines
1.2 KiB
JavaScript
Executable File

module.exports = {
extends: [
'eslint:recommended',
'plugin:react/recommended',
],
env: {
browser: true,
node: true
},
parserOptions: {
ecmaVersion: 6
},
settings: {
react: {
pragma: "preact",
version: "15.0",
}
},
rules: {
// prevents stupid complaints a la
// (req) {
// req.something = x;
// }
'no-param-reassign': [2, { props: false }],
'no-multi-spaces': [0],
'max-len': ['error', 120],
'import/no-extraneous-dependencies': [0],
'prefer-arrow-callback': [0],
'arrow-body-style': [0],
'no-return-assign': [2, 'except-parens'],
'no-console': [0],
// i like loops
'no-plusplus': [0],
'no-await-in-loop': [0],
'indent': ['error', 4],
'keyword-spacing': ['error'],
'key-spacing': ['error'],
// for preact
"react/react-in-jsx-scope": [0],
"react/jsx-indent": [2, 4],
"react/jsx-uses-react": 1,
"react/jsx-uses-vars": 1,
"react/prefer-stateless-function": 1,
"react/prop-types": 0
},
};