Commit e62e3e7b by Jaxon

style: 简单更新

1 parent 76bc07ee
module.exports = { module.exports = {
root: true, root: true,
parserOptions: { parserOptions: {
// parser: '@babel/eslint-parser' // parser: '@babel/eslint-parser'
ecmaVersion: 2020 ecmaVersion: 2020
}, },
env: { env: {
browser: true browser: true
}, },
extends: [ extends: [
// https://github.com/vuejs/eslint-plugin-vue#priority-a-essential-error-prevent // https://github.com/vuejs/eslint-plugin-vue#priority-a-essential-error-prevent
// ion consider switching to `plugin:vue/strongly-recommended` or // ion consider switching to `plugin:vue/strongly-recommended` or
// `plugin:vue/recommended` for stricter rules. // `plugin:vue/recommended` for stricter rules.
"plugin:vue/essential", "plugin:vue/essential",
// https://github.com/standard/standard/blob/master/docs/RULES-en.md // https://github.com/standard/standard/blob/master/docs/RULES-en.md
"standard", "standard",
"plugin:vue/strongly-recommended", "plugin:vue/strongly-recommended",
"@vue/standard" "@vue/standard"
// '@vue/typescript/recommended' // '@vue/typescript/recommended'
], ],
// required to lint *.vue files // required to lint *.vue files
plugins: ["vue"], plugins: ["vue"],
globals: { globals: {
NODE_ENV: false, NODE_ENV: false,
_: false, _: false,
echarts: false echarts: false
}, },
rules: { rules: {
"vue/max-attributes-per-line": [ "vue/max-attributes-per-line": [
0, 2,
{ {
singleline: 10, singleline: 2,
multiline: { multiline: {
max: 2, max: 1,
allowFirstLine: false allowFirstLine: true
} }
} }
], ],
"vue/html-closing-bracket-newline": [ "vue/html-closing-bracket-newline": [
"error", "error",
{ {
singleline: "never", singleline: "never",
multiline: "never" multiline: "never"
} }
], ],
"vue/singleline-html-element-content-newline": "off", "vue/singleline-html-element-content-newline": "off",
"vue/multiline-html-element-content-newline": "off", "vue/multiline-html-element-content-newline": "off",
"vue/name-property-casing": ["error", "PascalCase"], "vue/name-property-casing": ["error", "PascalCase"],
"vue/no-v-html": "off", "vue/no-v-html": "off",
"arrow-spacing": [ "arrow-spacing": [
2, 2,
{ {
before: true, before: true,
after: true after: true
} }
], ],
"no-var": "off", "no-var": "off",
eqeqeq: "off", eqeqeq: "off",
// 'no-eval': ['error', { allowIndirect: false }], // default is false // 'no-eval': ['error', { allowIndirect: false }], // default is false
"no-eval": "off", // default is false "no-eval": "off", // default is false
// allow async-await // allow async-await
"generator-star-spacing": "off", "generator-star-spacing": "off",
// 'block-spacing': [2, 'always'], // 'block-spacing': [2, 'always'],
"brace-style": [ "brace-style": [
2, 2,
"1tbs", "1tbs",
{ {
allowSingleLine: true allowSingleLine: true
} }
], ],
"comma-dangle": [2, "never"], "comma-dangle": [2, "never"],
"comma-spacing": [ "comma-spacing": [
2, 2,
{ {
before: false, before: false,
after: true after: true
} }
], ],
"comma-style": [2, "last"], "comma-style": [2, "last"],
curly: [2, "multi-line"], curly: [2, "multi-line"],
"dot-location": [2, "property"], "dot-location": [2, "property"],
indent: [ indent: [
2, 2,
2, 2,
{ {
SwitchCase: 1 SwitchCase: 1
} }
], ],
"key-spacing": [ "key-spacing": [
2, 2,
{ {
beforeColon: false, beforeColon: false,
afterColon: true afterColon: true
} }
], ],
"keyword-spacing": [ "keyword-spacing": [
2, 2,
{ {
before: true, before: true,
after: true after: true
} }
], ],
"new-cap": [ "new-cap": [
2, 2,
{ {
newIsCap: true, newIsCap: true,
capIsNew: false capIsNew: false
} }
], ],
"no-extra-parens": [2, "functions"], "no-extra-parens": [2, "functions"],
"no-floating-decimal": 2, "no-floating-decimal": 2,
"no-multi-spaces": 2, "no-multi-spaces": 2,
"no-multiple-empty-lines": [ "no-multiple-empty-lines": [
2, 2,
{ {
max: 1 max: 1
} }
], ],
"no-trailing-spaces": 2, "no-trailing-spaces": 2,
quotes: [ quotes: [
0, 0,
"single", "single",
{ {
avoidEscape: true, avoidEscape: true,
allowTemplateLiterals: true allowTemplateLiterals: true
} }
], ],
semi: [2, "never"], semi: [2, "never"],
"space-before-blocks": [2, "always"], "space-before-blocks": [2, "always"],
// 'space-before-function-paren': [2, 'never'], // 'space-before-function-paren': [2, 'never'],
"space-before-function-paren": 0, "space-before-function-paren": 0,
"space-in-parens": [2, "never"], "space-in-parens": [2, "never"],
"space-infix-ops": 2, "space-infix-ops": 2,
"space-unary-ops": [ "space-unary-ops": [
2, 2,
{ {
words: true, words: true,
nonwords: false nonwords: false
} }
], ],
"spaced-comment": [2, "always"], "spaced-comment": [2, "always"],
"prefer-const": 2, "prefer-const": 2,
"node/no-callback-literal": 'off', "node/no-callback-literal": 'off',
"no-unused-expressions": "off", "no-unused-expressions": "off",
camelcase: 'off', camelcase: 'off',
"no-undef": 'off', "no-undef": 'off',
"vue/html-self-closing": 'off', "vue/html-self-closing": 'off',
"array-callback-return": 'off' "array-callback-return": 'off'
} }
} }
...@@ -3662,27 +3662,6 @@ ...@@ -3662,27 +3662,6 @@
"whatwg-fetch": "^3.6.2" "whatwg-fetch": "^3.6.2"
}, },
"dependencies": { "dependencies": {
"@vue/vue-loader-v15": {
"version": "npm:vue-loader@15.11.1",
"resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-15.11.1.tgz",
"integrity": "sha512-0iw4VchYLePqJfJu9s62ACWUXeSqM30SQqlIftbYWM3C+jpPcEHKSPUZBLjSF9au4HTHQ/naF6OGnO3Q/qGR3Q==",
"dev": true,
"requires": {
"@vue/component-compiler-utils": "^3.1.0",
"hash-sum": "^1.0.2",
"loader-utils": "^1.1.0",
"vue-hot-reload-api": "^2.3.0",
"vue-style-loader": "^4.1.0"
},
"dependencies": {
"hash-sum": {
"version": "1.0.2",
"resolved": "https://registry.npmmirror.com/hash-sum/-/hash-sum-1.0.2.tgz",
"integrity": "sha512-fUs4B4L+mlt8/XAtSOGMUO1TXmAelItBPtJG7CyHJfYTdDjwisntGO2JQz7oUsatOY9o68+57eziUVNw/mRHmA==",
"dev": true
}
}
},
"acorn-walk": { "acorn-walk": {
"version": "8.2.0", "version": "8.2.0",
"resolved": "https://registry.npmmirror.com/acorn-walk/-/acorn-walk-8.2.0.tgz", "resolved": "https://registry.npmmirror.com/acorn-walk/-/acorn-walk-8.2.0.tgz",
...@@ -3717,12 +3696,6 @@ ...@@ -3717,12 +3696,6 @@
} }
} }
}, },
"caniuse-lite": {
"version": "1.0.30001429",
"resolved": "https://registry.npmmirror.com/caniuse-lite/-/caniuse-lite-1.0.30001429.tgz",
"integrity": "sha512-511ThLu1hF+5RRRt0zYCf2U2yRr9GPF6m5y90SBCWsvSoYoW7yAGlv/elyPaNfvGCkp6kj/KFZWU0BMA69Prsg==",
"dev": true
},
"debug": { "debug": {
"version": "4.3.4", "version": "4.3.4",
"resolved": "https://registry.npmmirror.com/debug/-/debug-4.3.4.tgz", "resolved": "https://registry.npmmirror.com/debug/-/debug-4.3.4.tgz",
...@@ -4072,6 +4045,27 @@ ...@@ -4072,6 +4045,27 @@
"lodash": "^4.17.4" "lodash": "^4.17.4"
} }
}, },
"@vue/vue-loader-v15": {
"version": "npm:vue-loader@15.11.1",
"resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-15.11.1.tgz",
"integrity": "sha512-0iw4VchYLePqJfJu9s62ACWUXeSqM30SQqlIftbYWM3C+jpPcEHKSPUZBLjSF9au4HTHQ/naF6OGnO3Q/qGR3Q==",
"dev": true,
"requires": {
"@vue/component-compiler-utils": "^3.1.0",
"hash-sum": "^1.0.2",
"loader-utils": "^1.1.0",
"vue-hot-reload-api": "^2.3.0",
"vue-style-loader": "^4.1.0"
},
"dependencies": {
"hash-sum": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/hash-sum/-/hash-sum-1.0.2.tgz",
"integrity": "sha512-fUs4B4L+mlt8/XAtSOGMUO1TXmAelItBPtJG7CyHJfYTdDjwisntGO2JQz7oUsatOY9o68+57eziUVNw/mRHmA==",
"dev": true
}
}
},
"@vue/vue2-jest": { "@vue/vue2-jest": {
"version": "27.0.0", "version": "27.0.0",
"resolved": "https://registry.npmmirror.com/@vue/vue2-jest/-/vue2-jest-27.0.0.tgz", "resolved": "https://registry.npmmirror.com/@vue/vue2-jest/-/vue2-jest-27.0.0.tgz",
...@@ -5398,9 +5392,9 @@ ...@@ -5398,9 +5392,9 @@
} }
}, },
"caniuse-lite": { "caniuse-lite": {
"version": "1.0.30001388", "version": "1.0.30001763",
"resolved": "https://registry.npmmirror.com/caniuse-lite/-/caniuse-lite-1.0.30001388.tgz", "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001763.tgz",
"integrity": "sha512-znVbq4OUjqgLxMxoNX2ZeeLR0d7lcDiE5uJ4eUiWdml1J1EkxbnQq6opT9jb9SMfJxB0XA16/ziHwni4u1I3GQ==", "integrity": "sha512-mh/dGtq56uN98LlNX9qdbKnzINhX0QzhiWBFEkFfsFO4QyCvL8YegrJAazCwXIeqkIob8BlZPGM3xdnY+sgmvQ==",
"dev": true "dev": true
}, },
"canvg": { "canvg": {
...@@ -14555,12 +14549,6 @@ ...@@ -14555,12 +14549,6 @@
} }
} }
}, },
"caniuse-lite": {
"version": "1.0.30001429",
"resolved": "https://registry.npmmirror.com/caniuse-lite/-/caniuse-lite-1.0.30001429.tgz",
"integrity": "sha512-511ThLu1hF+5RRRt0zYCf2U2yRr9GPF6m5y90SBCWsvSoYoW7yAGlv/elyPaNfvGCkp6kj/KFZWU0BMA69Prsg==",
"dev": true
},
"electron-to-chromium": { "electron-to-chromium": {
"version": "1.4.284", "version": "1.4.284",
"resolved": "https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.4.284.tgz", "resolved": "https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.4.284.tgz",
......
...@@ -23,8 +23,10 @@ ...@@ -23,8 +23,10 @@
"@sentry/webpack-plugin": "^1.18.9", "@sentry/webpack-plugin": "^1.18.9",
"ali-oss": "^6.22.0", "ali-oss": "^6.22.0",
"axios": "^0.18.0", "axios": "^0.18.0",
"baseline-browser-mapping": "^2.9.13",
"better-scroll": "^1.15.2", "better-scroll": "^1.15.2",
"bignumber.js": "^9.1.1", "bignumber.js": "^9.1.1",
"caniuse-lite": "^1.0.30001763",
"core-js": "^3.8.3", "core-js": "^3.8.3",
"dayjs": "^1.8.12", "dayjs": "^1.8.12",
"default-passive-events": "^2.0.0", "default-passive-events": "^2.0.0",
...@@ -94,5 +96,8 @@ ...@@ -94,5 +96,8 @@
"script-loader": "^0.7.2", "script-loader": "^0.7.2",
"vue-template-compiler": "^2.5.21", "vue-template-compiler": "^2.5.21",
"webpack": "^5.74.0" "webpack": "^5.74.0"
},
"volta": {
"node": "14.21.3"
} }
} }
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!