Skip to content

Commit 607f05a

Browse files
committed
node18
1 parent ae473d9 commit 607f05a

File tree

11 files changed

+190
-489
lines changed

11 files changed

+190
-489
lines changed

.eslintrc.js

Lines changed: 9 additions & 192 deletions
Original file line numberDiff line numberDiff line change
@@ -1,202 +1,19 @@
1+
// .eslintrc.js
12
module.exports = {
23
root: true,
3-
parserOptions: {
4-
parser: 'babel-eslint',
5-
sourceType: 'module'
6-
},
74
env: {
85
browser: true,
96
node: true,
10-
es6: true,
7+
es2021: true
118
},
129
extends: ['plugin:vue/recommended', 'eslint:recommended'],
13-
14-
// add your custom rules here
15-
//it is base on https://github.com/vuejs/eslint-config-vue
10+
parserOptions: {
11+
parser: '@babel/eslint-parser',
12+
sourceType: 'module',
13+
requireConfigFile: false
14+
},
1615
rules: {
17-
"vue/max-attributes-per-line": [2, {
18-
"singleline": 10,
19-
"multiline": {
20-
"max": 1,
21-
"allowFirstLine": false
22-
}
23-
}],
24-
// "vue/singleline-html-element-content-newline": "off",
25-
// "vue/multiline-html-element-content-newline":"off",
26-
// "vue/name-property-casing": ["error", "PascalCase"],
27-
// "vue/no-v-html": "off",
28-
// 'accessor-pairs': 2,
29-
// 'arrow-spacing': [2, {
30-
// 'before': true,
31-
// 'after': true
32-
// }],
33-
// 'block-spacing': [2, 'always'],
34-
// 'brace-style': [2, '1tbs', {
35-
// 'allowSingleLine': true
36-
// }],
37-
// 'camelcase': [0, {
38-
// 'properties': 'always'
39-
// }],
40-
// // json 最后一个属性是否可以有逗号
41-
// 'comma-dangle': 0,
42-
// // 'comma-spacing': [2, {
43-
// // 'before': false,
44-
// // 'after': true
45-
// // }],
46-
// 'comma-style': [2, 'last'],
47-
// 'constructor-super': 2,
48-
// 'curly': [2, 'multi-line'],
49-
// 'dot-location': [2, 'property'],
50-
// 'eol-last': 2,
51-
// 'eqeqeq': ["error", "always", {"null": "ignore"}],
52-
// 'generator-star-spacing': [2, {
53-
// 'before': true,
54-
// 'after': true
55-
// }],
56-
// 'handle-callback-err': [2, '^(err|error)$'],
57-
// 'indent': [2, 2, {
58-
// 'SwitchCase': 1
59-
// }],
60-
// 'jsx-quotes': [2, 'prefer-single'],
61-
// 'key-spacing': [2, {
62-
// 'beforeColon': false,
63-
// 'afterColon': true
64-
// }],
65-
// 'keyword-spacing': [2, {
66-
// 'before': true,
67-
// 'after': true
68-
// }],
69-
// 'new-cap': [2, {
70-
// 'newIsCap': true,
71-
// 'capIsNew': false
72-
// }],
73-
// 'new-parens': 2,
74-
// 'no-array-constructor': 2,
75-
// 'no-caller': 2,
76-
// 'no-console': 'off',
77-
// 'no-class-assign': 2,
78-
// 'no-cond-assign': 2,
79-
// 'no-const-assign': 2,
80-
// 'no-control-regex': 0,
81-
// 'no-delete-var': 2,
82-
// 'no-dupe-args': 2,
83-
// 'no-dupe-class-members': 2,
84-
// 'no-dupe-keys': 2,
85-
// 'no-duplicate-case': 2,
86-
// 'no-empty-character-class': 2,
87-
// 'no-empty-pattern': 2,
88-
// 'no-eval': 2,
89-
// 'no-ex-assign': 2,
90-
// 'no-extend-native': 2,
91-
// 'no-extra-bind': 2,
92-
// 'no-extra-boolean-cast': 2,
93-
// 'no-extra-parens': [2, 'functions'],
94-
// 'no-fallthrough': 2,
95-
// 'no-floating-decimal': 2,
96-
// 'no-func-assign': 2,
97-
// 'no-implied-eval': 2,
98-
// 'no-inner-declarations': [2, 'functions'],
99-
// 'no-invalid-regexp': 2,
100-
// 'no-irregular-whitespace': 2,
101-
// 'no-iterator': 2,
102-
// 'no-label-var': 2,
103-
// 'no-labels': [2, {
104-
// 'allowLoop': false,
105-
// 'allowSwitch': false
106-
// }],
107-
// 'no-lone-blocks': 2,
108-
// 'no-mixed-spaces-and-tabs': 2,
109-
// 'no-multi-spaces': 2,
110-
// 'no-multi-str': 2,
111-
// 'no-multiple-empty-lines': [2, {
112-
// 'max': 1
113-
// }],
114-
// 'no-native-reassign': 2,
115-
// 'no-negated-in-lhs': 2,
116-
// 'no-new-object': 2,
117-
// 'no-new-require': 2,
118-
// 'no-new-symbol': 2,
119-
// 'no-new-wrappers': 2,
120-
// 'no-obj-calls': 2,
121-
// 'no-octal': 2,
122-
// 'no-octal-escape': 2,
123-
// 'no-path-concat': 2,
124-
// 'no-proto': 2,
125-
// 'no-redeclare': 2,
126-
// 'no-regex-spaces': 2,
127-
// 'no-return-assign': [2, 'except-parens'],
128-
// 'no-self-assign': 2,
129-
// 'no-self-compare': 2,
130-
// 'no-sequences': 2,
131-
// 'no-shadow-restricted-names': 2,
132-
// 'no-spaced-func': 2,
133-
// 'no-sparse-arrays': 2,
134-
// 'no-this-before-super': 2,
135-
// 'no-throw-literal': 2,
136-
// 'no-trailing-spaces': 2,
137-
// 'no-undef': 2,
138-
// 'no-undef-init': 2,
139-
// 'no-unexpected-multiline': 2,
140-
// 'no-unmodified-loop-condition': 2,
141-
// 'no-unneeded-ternary': [2, {
142-
// 'defaultAssignment': false
143-
// }],
144-
// 'no-unreachable': 2,
145-
// 'no-unsafe-finally': 2,
146-
'no-unused-vars': [2, {
147-
'vars': 'all',
148-
'args': 'none'
149-
}],
150-
// 'no-useless-call': 2,
151-
// 'no-useless-computed-key': 2,
152-
// 'no-useless-constructor': 2,
153-
// 'no-useless-escape': 0,
154-
// 'no-whitespace-before-property': 2,
155-
// 'no-with': 2,
156-
// 'one-var': [2, {
157-
// 'initialized': 'never'
158-
// }],
159-
// 'operator-linebreak': [2, 'after', {
160-
// 'overrides': {
161-
// '?': 'before',
162-
// ':': 'before'
163-
// }
164-
// }],
165-
// 'padded-blocks': [2, 'never'],
166-
// // 字符串引号使用规则,单引号,双引号,反引号
167-
// // 'quotes': [2, 'single', {
168-
// // 'avoidEscape': true,
169-
// // 'allowTemplateLiterals': true
170-
// // }],
171-
// // 结尾不允许使用分号[2, 'never'], 必须使用分号[2, 'always'], 忽略semi:0
172-
// 'semi': 0,
173-
// 'semi-spacing': [2, {
174-
// 'before': false,
175-
// 'after': true
176-
// }],
177-
// // 代码块,例如大括号,不允许有空格[2, 'never'], 必须有空格[2, 'always'], 忽略0
178-
// 'space-before-blocks': 0,
179-
// 'space-before-function-paren': [2, 'never'],
180-
// 'space-in-parens': [2, 'never'],
181-
// 'space-infix-ops': 2,
182-
// 'space-unary-ops': [2, {
183-
// 'words': true,
184-
// 'nonwords': false
185-
// }],
186-
// 'spaced-comment': [2, 'always', {
187-
// 'markers': ['global', 'globals', 'eslint', 'eslint-disable', '*package', '!', ',']
188-
// }],
189-
// 'template-curly-spacing': [2, 'never'],
190-
// 'use-isnan': 2,
191-
// 'valid-typeof': 2,
192-
// 'wrap-iife': [2, 'any'],
193-
// 'yield-star-spacing': [2, 'both'],
194-
// 'yoda': [2, 'never'],
195-
// 'prefer-const': 2,
196-
// 'no-debugger': process.env.NODE_ENV === 'production' ? 2 : 0,
197-
// 'object-curly-spacing': [2, 'always', {
198-
// objectsInObjects: false
199-
// }],
200-
// 'array-bracket-spacing': [2, 'never']
16+
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
17+
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off'
20118
}
20219
}

Dockerfile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1-
FROM node:10.17.0-stretch AS builder
1+
FROM node:18 AS builder
22
WORKDIR /workspace
3+
COPY package*.json ./
4+
RUN npm install
35
COPY . .
4-
RUN npm install && npm run build:prod
6+
RUN npm run build:prod
57

68
FROM nginx:mainline-alpine
79

babel.config.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
11
module.exports = {
2-
presets: [
3-
'@vue/app'
4-
]
2+
presets: ['@vue/cli-plugin-babel/preset']
53
}

jsconfig.json

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,20 @@
22
"compilerOptions": {
33
"baseUrl": "./",
44
"paths": {
5-
"@/*": ["src/*"]
6-
}
5+
"@/*": ["src/*"]
6+
},
7+
"target": "es6",
8+
"module": "commonjs",
9+
"allowSyntheticDefaultImports": true,
10+
"checkJs": false,
11+
"jsx": "preserve",
12+
"types": [
13+
"@babel/core",
14+
"node"
15+
]
716
},
8-
"exclude": ["node_modules", "dist"]
17+
"exclude": ["node_modules", "dist"],
18+
"include": [
19+
"src/**/*"
20+
]
921
}

package.json

Lines changed: 44 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -15,62 +15,58 @@
1515
"svgo": "svgo -f src/icons/svg --config=src/icons/svgo.yml"
1616
},
1717
"dependencies": {
18-
"@antv/data-set": "^0.10.2",
19-
"@antv/g2": "^3.5.9",
18+
"@antv/data-set": "^0.11.8",
19+
"@antv/g2": "^4.2.10",
2020
"af-table-column": "^1.0.3",
21-
"axios": ">=0.21.1",
22-
"element-ui": "^2.12.0",
23-
"github-markdown-css": "^3.0.1",
24-
"html-loader": "^0.5.5",
25-
"js-base64": "^2.5.1",
26-
"js-cookie": "2.2.0",
27-
"markdown-loader": "^5.1.0",
28-
"normalize.css": "7.0.0",
29-
"nprogress": "0.2.0",
30-
"path-to-regexp": "3.3.0",
21+
"axios": "^1.6.2",
22+
"element-ui": "^2.15.14",
23+
"js-base64": "^3.7.5",
24+
"js-cookie": "^3.0.5",
25+
"normalize.css": "^8.0.1",
26+
"nprogress": "^0.2.0",
27+
"path-browserify": "^1.0.1",
28+
"path-to-regexp": "^6.2.1",
3129
"qrcode.vue": "^1.7.0",
32-
"showdown": "^1.9.0",
33-
"vue": "2.6.10",
34-
"vue-json-viewer": "^2.2.8",
35-
"vue-markdown-loader": "^2.4.1",
36-
"vue-moment": "4.1.0",
37-
"vue-router": "3.0.6",
38-
"vuex": "3.1.0"
30+
"showdown": "^2.1.0",
31+
"vue": "^2.7.16",
32+
"vue-json-viewer": "^2.2.22",
33+
"vue-moment": "^4.1.0",
34+
"vue-router": "^3.6.5",
35+
"vuex": "^3.6.2"
3936
},
4037
"devDependencies": {
41-
"@babel/core": "7.0.0",
42-
"@babel/register": "7.0.0",
43-
"@vue/cli-plugin-babel": "3.6.0",
44-
"@vue/cli-plugin-eslint": "^3.9.1",
45-
"@vue/cli-plugin-unit-jest": "3.6.3",
46-
"@vue/cli-service": "3.6.0",
47-
"@vue/test-utils": "1.0.0-beta.29",
48-
"autoprefixer": "^9.5.1",
49-
"babel-core": "7.0.0-bridge.0",
50-
"babel-eslint": "10.0.1",
51-
"babel-jest": "23.6.0",
52-
"chalk": "2.4.2",
53-
"connect": "3.6.6",
54-
"eslint": "5.15.3",
55-
"eslint-plugin-vue": "5.2.2",
56-
"html-webpack-plugin": "3.2.0",
57-
"mockjs": "1.0.1-beta3",
58-
"node-sass": "^4.14.1",
59-
"runjs": "^4.3.2",
60-
"sass-loader": "^10.0.1",
61-
"script-ext-html-webpack-plugin": "2.1.3",
62-
"script-loader": "0.7.2",
63-
"serve-static": "^1.13.2",
64-
"svg-sprite-loader": "4.1.3",
65-
"svgo": "1.2.2",
66-
"vue-template-compiler": "2.6.10"
38+
"@babel/core": "^7.23.5",
39+
"@babel/register": "^7.22.15",
40+
"@vue/cli-plugin-babel": "^5.0.8",
41+
"@vue/cli-plugin-eslint": "^5.0.8",
42+
"@vue/cli-plugin-unit-jest": "^5.0.8",
43+
"@vue/cli-service": "^5.0.8",
44+
"@vue/test-utils": "^1.3.6",
45+
"autoprefixer": "^10.4.16",
46+
"babel-core": "^7.0.0-bridge.0",
47+
"babel-eslint": "^10.1.0",
48+
"babel-jest": "^29.7.0",
49+
"chalk": "^4.1.2",
50+
"connect": "^3.7.0",
51+
"eslint": "^8.55.0",
52+
"eslint-plugin-vue": "^9.19.2",
53+
"html-webpack-plugin": "^4",
54+
"mockjs": "^1.1.0",
55+
"sass": "^1.69.5",
56+
"sass-loader": "^13.3.2",
57+
"script-loader": "^0.7.2",
58+
"serve-static": "^1.15.0",
59+
"svg-sprite-loader": "^6.0.11",
60+
"svgo": "^3.0.4",
61+
"vue-template-compiler": "^2.7.16"
6762
},
6863
"engines": {
69-
"node": ">=8.9",
70-
"npm": ">= 3.0.0"
64+
"node": ">=18.20.0 <19",
65+
"npm": ">= 9.0.0"
7166
},
7267
"browserslist": [
7368
"> 1%",
74-
"last 2 versions"
69+
"last 2 versions",
70+
"not dead"
7571
]
7672
}

src/layout/components/Navbar.vue

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,6 @@
3838
<i class="iconfont icon-lock"></i>Change Password
3939
</el-dropdown-item>
4040
</router-link>
41-
<a target="_blank" href="https://github.com/laoshanxi/app-mesh">
42-
<el-dropdown-item>
43-
<i class="iconfont icon-github"></i>Github
44-
</el-dropdown-item>
45-
</a>
4641
<a target="_blank" href="/ui/dc1/kv">
4742
<el-dropdown-item>
4843
<i class="el-icon-mobile-phone"></i>Consul

0 commit comments

Comments
 (0)