habitica-self-host/website/client/.eslintrc.js

32 lines
797 B
JavaScript
Raw Normal View History

2019-10-15 13:32:53 +00:00
/* eslint-disable import/no-commonjs */
module.exports = {
root: true,
env: {
2019-10-09 18:08:36 +00:00
node: true,
},
2019-10-09 18:08:36 +00:00
extends: [
'habitrpg/lib/vue',
],
ignorePatterns: ['dist/', 'node_modules/'],
rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
2019-10-09 18:08:36 +00:00
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
2019-10-12 15:14:09 +00:00
// TODO find a way to let eslint understand webpack aliases
2019-10-10 20:15:58 +00:00
'import/no-unresolved': 'off',
2019-10-12 14:33:05 +00:00
'vue/no-v-html': 'off',
'vue/html-self-closing': ['error', {
html: {
void: 'never',
2019-10-12 15:14:09 +00:00
// Otherwise it results in self closing span(s) and div(s)
2019-10-12 14:33:05 +00:00
normal: 'never',
component: 'always',
},
svg: 'never',
math: 'never',
}],
},
parserOptions: {
2019-10-09 18:08:36 +00:00
parser: 'babel-eslint',
},
2019-10-09 18:08:36 +00:00
};