提交 4009243e 作者: 方治民

feat: 升级依赖,增加 lint script,修复 eslint/stylelint 问题

上级 77ee9fdd
......@@ -68,5 +68,6 @@ module.exports = {
},
],
'vue/multi-word-component-names': 'off',
'vue/no-reserved-component-names': 'off',
},
}
......@@ -34,6 +34,7 @@
"log": "conventional-changelog -p angular -i CHANGELOG.md -s",
"clean:cache": "rimraf node_modules/.cache/ && rimraf node_modules/.vite",
"clean:lib": "rimraf node_modules",
"lint": "npm run lint:eslint && npm run lint:prettier && npm run lint:stylelint",
"lint:eslint": "eslint --cache --max-warnings 0 \"{src,mock}/**/*.{vue,ts,tsx}\" --fix",
"lint:prettier": "prettier --write \"src/**/*.{js,json,tsx,css,less,scss,vue,html,md}\"",
"lint:stylelint": "stylelint --cache --fix \"**/*.{vue,less,postcss,css,scss}\" --cache --cache-location node_modules/.cache/stylelint/",
......@@ -54,16 +55,16 @@
"@ant-design/colors": "^6.0.0",
"@ant-design/icons-vue": "^6.1.0",
"@iconify/iconify": "^2.2.1",
"@logicflow/core": "^1.1.15",
"@logicflow/extension": "^1.1.15",
"@vue/runtime-core": "^3.2.33",
"@vue/shared": "^3.2.33",
"@vueuse/core": "^8.4.2",
"@vueuse/shared": "^8.4.2",
"@logicflow/core": "^1.1.18",
"@logicflow/extension": "^1.1.18",
"@vue/runtime-core": "^3.2.36",
"@vue/shared": "^3.2.36",
"@vueuse/core": "^8.5.0",
"@vueuse/shared": "^8.5.0",
"@zxcvbn-ts/core": "^2.0.1",
"ant-design-vue": "^3.2.3",
"ant-design-vue": "^3.2.5",
"axios": "^0.26.1",
"codemirror": "^5.65.3",
"codemirror": "^5.65.4",
"cropperjs": "^1.5.12",
"crypto-js": "^4.1.1",
"dayjs": "^1.11.2",
......@@ -80,9 +81,9 @@
"resize-observer-polyfill": "^1.5.1",
"showdown": "^2.1.0",
"sortablejs": "^1.15.0",
"tinymce": "^5.10.4",
"vditor": "^3.8.14",
"vue": "^3.2.33",
"tinymce": "^5.10.5",
"vditor": "^3.8.15",
"vue": "^3.2.36",
"vue-i18n": "^9.1.10",
"vue-json-pretty": "^2.1.0",
"vue-router": "^4.0.15",
......@@ -90,9 +91,9 @@
"xlsx": "^0.18.5"
},
"devDependencies": {
"@commitlint/cli": "^16.2.4",
"@commitlint/cli": "^17.0.1",
"@commitlint/config-conventional": "^16.2.4",
"@iconify/json": "^2.1.43",
"@iconify/json": "^2.1.50",
"@purge-icons/generated": "^0.8.1",
"@types/codemirror": "^5.60.5",
"@types/crypto-js": "^4.1.1",
......@@ -101,29 +102,29 @@
"@types/intro.js": "^3.0.2",
"@types/lodash-es": "^4.17.6",
"@types/mockjs": "^1.0.6",
"@types/node": "^17.0.33",
"@types/node": "^17.0.35",
"@types/nprogress": "^0.2.0",
"@types/qrcode": "^1.4.2",
"@types/qs": "^6.9.7",
"@types/showdown": "^1.9.4",
"@types/sortablejs": "^1.13.0",
"@typescript-eslint/eslint-plugin": "^5.23.0",
"@typescript-eslint/parser": "^5.23.0",
"@typescript-eslint/eslint-plugin": "^5.26.0",
"@typescript-eslint/parser": "^5.26.0",
"@vitejs/plugin-legacy": "^1.8.2",
"@vitejs/plugin-vue": "^2.3.3",
"@vitejs/plugin-vue-jsx": "^1.3.10",
"@vue/compiler-sfc": "3.2.31",
"@vue/test-utils": "^2.0.0-rc.21",
"@vue/test-utils": "^2.0.0",
"autoprefixer": "^10.4.7",
"commitizen": "^4.2.4",
"conventional-changelog-cli": "^2.2.2",
"cross-env": "^7.0.3",
"cz-conventional-changelog": "^3.3.0",
"dotenv": "^16.0.1",
"eslint": "^8.15.0",
"eslint": "^8.16.0",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-vue": "^8.7.1",
"eslint-plugin-vue": "^9.0.1",
"esno": "^0.14.1",
"fs-extra": "^10.1.0",
"husky": "^7.0.4",
......@@ -133,27 +134,27 @@
"npm-run-all": "^4.1.5",
"picocolors": "^1.0.0",
"pont-engine": "^1.3.1",
"postcss": "^8.4.13",
"postcss": "^8.4.14",
"postcss-html": "^1.4.1",
"postcss-less": "^6.0.0",
"prettier": "^2.6.2",
"rimraf": "^3.0.2",
"rollup": "^2.73.0",
"rollup": "^2.74.1",
"rollup-plugin-visualizer": "^5.6.0",
"sort-package-json": "^1.57.0",
"stylelint": "^14.8.2",
"stylelint": "^14.8.5",
"stylelint-config-prettier": "^9.0.3",
"stylelint-config-recommended": "^7.0.0",
"stylelint-config-recommended-vue": "^1.4.0",
"stylelint-config-standard": "^25.0.0",
"stylelint-order": "^5.0.0",
"ts-node": "^10.7.0",
"typescript": "^4.6.4",
"unplugin-auto-import": "^0.7.1",
"ts-node": "^10.8.0",
"typescript": "^4.7.2",
"unplugin-auto-import": "^0.7.2",
"vite": "^2.9.9",
"vite-plugin-compression": "^0.5.1",
"vite-plugin-html": "^3.2.0",
"vite-plugin-mkcert": "^1.6.0",
"vite-plugin-mkcert": "^1.6.4",
"vite-plugin-mock": "^2.9.6",
"vite-plugin-optimize-persist": "^0.1.2",
"vite-plugin-package-config": "^0.1.1",
......@@ -164,8 +165,8 @@
"vite-plugin-theme": "^0.8.6",
"vite-plugin-vue-setup-extend": "^0.4.0",
"vite-plugin-windicss": "^1.8.4",
"vue-eslint-parser": "^9.0.1",
"vue-tsc": "^0.34.13"
"vue-eslint-parser": "^9.0.2",
"vue-tsc": "^0.34.16"
},
"engines": {
"node": "^12 || >=14"
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -5,9 +5,7 @@
"description": "身份认证",
"interfaces": [
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "登录",
"name": "login",
"method": "post",
......@@ -91,9 +89,7 @@
"parameters": []
},
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "注册",
"name": "register",
"method": "post",
......@@ -405,10 +401,7 @@
"isDefsType": false,
"templateIndex": -1,
"compileTemplateKeyword": "#/definitions/",
"enum": [
"'ASC'",
"'DESC'"
],
"enum": ["'ASC'", "'DESC'"],
"typeProperties": []
}
}
......@@ -447,9 +440,7 @@
"description": "文件管理",
"interfaces": [
{
"consumes": [
"multipart/form-data"
],
"consumes": ["multipart/form-data"],
"description": "文件上传",
"name": "upload",
"method": "post",
......@@ -498,9 +489,7 @@
"description": "权限管理",
"interfaces": [
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "新增",
"name": "add",
"method": "post",
......@@ -686,11 +675,7 @@
"isDefsType": false,
"templateIndex": -1,
"compileTemplateKeyword": "#/definitions/",
"enum": [
"'DIR'",
"'MENU'",
"'BUTTON'"
],
"enum": ["'DIR'", "'MENU'", "'BUTTON'"],
"typeProperties": []
}
},
......@@ -712,9 +697,7 @@
]
},
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "删除",
"name": "deleted",
"method": "post",
......@@ -799,9 +782,7 @@
]
},
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "修改",
"name": "modify",
"method": "post",
......@@ -1002,11 +983,7 @@
"isDefsType": false,
"templateIndex": -1,
"compileTemplateKeyword": "#/definitions/",
"enum": [
"'DIR'",
"'MENU'",
"'BUTTON'"
],
"enum": ["'DIR'", "'MENU'", "'BUTTON'"],
"typeProperties": []
}
},
......@@ -1118,19 +1095,14 @@
"isDefsType": false,
"templateIndex": -1,
"compileTemplateKeyword": "#/definitions/",
"enum": [
"'ASC'",
"'DESC'"
],
"enum": ["'ASC'", "'DESC'"],
"typeProperties": []
}
}
]
},
{
"consumes": [
"application/x-www-form-urlencoded"
],
"consumes": ["application/x-www-form-urlencoded"],
"description": "树结构查询",
"name": "tree",
"method": "get",
......@@ -1189,9 +1161,7 @@
"description": "角色管理",
"interfaces": [
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "新增",
"name": "add",
"method": "post",
......@@ -1249,9 +1219,7 @@
]
},
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "分配权限",
"name": "assign",
"method": "post",
......@@ -1309,9 +1277,7 @@
]
},
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "删除",
"name": "deleted",
"method": "post",
......@@ -1396,9 +1362,7 @@
]
},
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "修改",
"name": "modify",
"method": "post",
......@@ -1561,10 +1525,7 @@
"isDefsType": false,
"templateIndex": -1,
"compileTemplateKeyword": "#/definitions/",
"enum": [
"'ASC'",
"'DESC'"
],
"enum": ["'ASC'", "'DESC'"],
"typeProperties": []
}
}
......@@ -1711,9 +1672,7 @@
"parameters": []
},
{
"consumes": [
"application/json"
],
"consumes": ["application/json"],
"description": "分配角色",
"name": "assign",
"method": "post",
......@@ -1861,10 +1820,7 @@
"isDefsType": false,
"templateIndex": -1,
"compileTemplateKeyword": "#/definitions/",
"enum": [
"'ASC'",
"'DESC'"
],
"enum": ["'ASC'", "'DESC'"],
"typeProperties": []
}
}
......@@ -2290,11 +2246,7 @@
"isDefsType": false,
"templateIndex": -1,
"compileTemplateKeyword": "#/definitions/",
"enum": [
"'DIR'",
"'MENU'",
"'BUTTON'"
],
"enum": ["'DIR'", "'MENU'", "'BUTTON'"],
"typeProperties": []
},
"name": "type",
......
import type { VNode, FunctionalComponent } from 'vue'
import { h } from 'vue'
import { isString } from '@vue/shared'
import { isString } from '/@/utils/is'
import { Icon } from '/@/components/Icon'
export const TreeIcon: FunctionalComponent = ({ icon }: { icon: VNode | string }) => {
......
// copy from element-plus
import { warn } from 'vue'
import { isObject } from '@vue/shared'
import { isObject } from './is'
import { fromPairs } from 'lodash-es'
import type { ExtractPropTypes, PropType } from '@vue/runtime-core'
import type { ExtractPropTypes, PropType } from 'vue'
import type { Mutable } from './types'
const wrapperKey = Symbol()
......
......@@ -74,7 +74,7 @@ module.exports = {
overrides: [
{
files: ['*.vue', '**/*.vue', '*.html', '**/*.html'],
extends: ['stylelint-config-recommended'],
extends: ['stylelint-config-recommended', 'stylelint-config-prettier', 'stylelint-config-recommended-vue'],
rules: {
'keyframes-name-pattern': null,
'selector-pseudo-class-no-unknown': [
......@@ -94,7 +94,7 @@ module.exports = {
{
files: ['*.less', '**/*.less'],
customSyntax: 'postcss-less',
extends: ['stylelint-config-standard', 'stylelint-config-recommended-vue'],
extends: ['stylelint-config-standard', 'stylelint-config-prettier', 'stylelint-config-recommended-vue'],
},
],
}
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论