From 91d3148f97ca59769648f9307f3d7e65b1bd7e95 Mon Sep 17 00:00:00 2001 From: Zero~Informatique Date: Sat, 21 Dec 2019 11:04:14 +0100 Subject: viewer: ESLint rules --- viewer/.eslintrc.js | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) (limited to 'viewer/.eslintrc.js') diff --git a/viewer/.eslintrc.js b/viewer/.eslintrc.js index be91544..76f59fd 100644 --- a/viewer/.eslintrc.js +++ b/viewer/.eslintrc.js @@ -1,14 +1,34 @@ module.exports = { root: true, + env: { node: true, }, - extends: ["plugin:vue/essential", "@vue/typescript"], + + 'extends': [ + 'plugin:vue/essential', + '@vue/typescript' + ], + rules: { "no-console": process.env.NODE_ENV === "production" ? "error" : "off", "no-debugger": process.env.NODE_ENV === "production" ? "error" : "off", + 'vue/attribute-hyphenation': 'warn', + 'vue/html-closing-bracket-spacing': 'warn', + 'vue/html-end-tags': 'error', + 'vue/html-quotes': 'warn', + 'vue/html-self-closing': 'warn', + 'vue/no-multi-spaces': 'warn', + 'vue/no-spaces-around-equal-signs-in-attribute': 'warn', + 'vue/no-template-shadow': 'error', + 'vue/v-bind-style': 'warn', + 'vue/v-on-style': 'warn', + 'vue/attributes-order': 'warn', + 'vue/this-in-template': 'warn' }, + parserOptions: { - parser: "@typescript-eslint/parser", + parser: '@typescript-eslint/parser', }, + }; -- cgit v1.2.3