Commit d5b645c6 authored by 曾沂轮's avatar 曾沂轮

Build: 添加@samrt/standard eslint规范

parent dbae82a7
...@@ -5,7 +5,7 @@ module.exports = { ...@@ -5,7 +5,7 @@ module.exports = {
}, },
'extends': [ 'extends': [
'plugin:vue/essential', 'plugin:vue/essential',
'@vue/standard' '@smart/standard'
], ],
rules: { rules: {
"comma-dangle": ["error", { "comma-dangle": ["error", {
...@@ -15,17 +15,19 @@ module.exports = { ...@@ -15,17 +15,19 @@ module.exports = {
"exports": "ignore", "exports": "ignore",
"functions": "ignore" "functions": "ignore"
}], }],
'generator-star-spacing': 'off',
"space-before-function-paren": ["error", { "space-before-function-paren": ["error", {
"anonymous": "always", "anonymous": "always",
"named": "never", "named": "never",
"asyncArrow": "always" "asyncArrow": "always"
}], }],
'template-curly-spacing': 'off', 'template-curly-spacing': ['error', 'always'],
'no-multi-spaces': ['error', { 'no-multi-spaces': ['error', {
'ignoreEOLComments': true 'ignoreEOLComments': true
}], }],
'no-trailing-spaces': 'off', 'no-trailing-spaces': ['error', {
'skipBlankLines': true,
'ignoreComments': true
}],
'no-useless-escape': 'error', 'no-useless-escape': 'error',
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off', 'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off' 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off'
......
...@@ -19,6 +19,7 @@ ...@@ -19,6 +19,7 @@
"vuex": "^3.0.1" "vuex": "^3.0.1"
}, },
"devDependencies": { "devDependencies": {
"@smart/eslint-config-standard": "^0.1.2",
"@vue/cli-plugin-babel": "^3.7.0", "@vue/cli-plugin-babel": "^3.7.0",
"@vue/cli-plugin-eslint": "^3.7.0", "@vue/cli-plugin-eslint": "^3.7.0",
"@vue/cli-plugin-unit-mocha": "^3.7.0", "@vue/cli-plugin-unit-mocha": "^3.7.0",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment