From f0cc6587e95f304d21ba611730b9a385e851123f Mon Sep 17 00:00:00 2001 From: icssoa <615206459@qq.com> Date: Tue, 1 Jun 2021 11:38:25 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=20vite=20=E5=92=8C=20vuedrag?= =?UTF-8?q?gable=20=E5=86=B2=E7=AA=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .eslintignore | 2 +- .eslintrc.js | 148 +++++++++++++-------------- package.json | 12 +-- src/cool/modules/task/views/task.vue | 2 +- src/core/set/router.ts | 3 + src/shims-vue.d.ts | 5 + yarn.lock | 90 +++++++++------- 7 files changed, 145 insertions(+), 117 deletions(-) diff --git a/.eslintignore b/.eslintignore index e785944..3c018ee 100644 --- a/.eslintignore +++ b/.eslintignore @@ -1 +1 @@ -vue.config.js \ No newline at end of file +vite.config.ts \ No newline at end of file diff --git a/.eslintrc.js b/.eslintrc.js index 3233db8..df549f7 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,76 +1,76 @@ module.exports = { - root: true, - env: { - browser: true, - node: true, - es6: true, - }, - parser: 'vue-eslint-parser', - parserOptions: { - parser: '@typescript-eslint/parser', - ecmaVersion: 2020, - sourceType: 'module', - jsxPragma: 'React', - ecmaFeatures: { - jsx: true, - tsx: true, - }, - }, - extends: [ - 'plugin:vue/vue3-recommended', - 'plugin:@typescript-eslint/recommended', - 'prettier', - 'plugin:prettier/recommended', - ], - rules: { - '@typescript-eslint/ban-ts-ignore': 'off', - '@typescript-eslint/explicit-function-return-type': 'off', - '@typescript-eslint/no-explicit-any': 'off', - '@typescript-eslint/no-var-requires': 'off', - '@typescript-eslint/no-empty-function': 'off', - 'vue/component-name-in-template-casing': ["error", "kebab-case"], - 'vue/component-definition-name-casing': ["error", "kebab-case"], - 'no-use-before-define': 'off', - '@typescript-eslint/no-use-before-define': 'off', - '@typescript-eslint/ban-ts-comment': 'off', - '@typescript-eslint/ban-types': 'off', - '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/explicit-module-boundary-types': 'off', - '@typescript-eslint/no-unused-vars': [ - 'error', - { - argsIgnorePattern: '^h$', - varsIgnorePattern: '^h$', - }, - ], - 'no-unused-vars': [ - 'error', - { - argsIgnorePattern: '^h$', - varsIgnorePattern: '^h$', - }, - ], - 'space-before-function-paren': 'off', - 'vue/attributes-order': 'off', - 'vue/one-component-per-file': 'off', - 'vue/html-closing-bracket-newline': 'off', - 'vue/max-attributes-per-line': 'off', - 'vue/multiline-html-element-content-newline': 'off', - 'vue/singleline-html-element-content-newline': 'off', - 'vue/attribute-hyphenation': 'off', - // 'vue/html-self-closing': 'off', - 'vue/require-default-prop': 'off', - 'vue/html-self-closing': [ - 'error', - { - html: { - void: 'always', - normal: 'never', - component: 'always', - }, - svg: 'always', - math: 'always', - }, - ], - }, + root: true, + env: { + browser: true, + node: true, + es6: true + }, + parser: "vue-eslint-parser", + parserOptions: { + parser: "@typescript-eslint/parser", + ecmaVersion: 2020, + sourceType: "module", + jsxPragma: "React", + ecmaFeatures: { + jsx: true, + tsx: true + } + }, + extends: [ + "plugin:vue/vue3-recommended", + "plugin:@typescript-eslint/recommended", + "prettier", + "plugin:prettier/recommended" + ], + rules: { + "@typescript-eslint/ban-ts-ignore": "off", + "@typescript-eslint/explicit-function-return-type": "off", + "@typescript-eslint/no-explicit-any": "off", + "@typescript-eslint/no-var-requires": "off", + "@typescript-eslint/no-empty-function": "off", + "vue/component-name-in-template-casing": ["error", "kebab-case"], + "vue/component-definition-name-casing": ["error", "kebab-case"], + "no-use-before-define": "off", + "@typescript-eslint/no-use-before-define": "off", + "@typescript-eslint/ban-ts-comment": "off", + "@typescript-eslint/ban-types": "off", + "@typescript-eslint/no-non-null-assertion": "off", + "@typescript-eslint/explicit-module-boundary-types": "off", + "@typescript-eslint/no-unused-vars": [ + "error", + { + argsIgnorePattern: "^h$", + varsIgnorePattern: "^h$" + } + ], + "no-unused-vars": [ + "error", + { + argsIgnorePattern: "^h$", + varsIgnorePattern: "^h$" + } + ], + "space-before-function-paren": "off", + "vue/attributes-order": "off", + "vue/one-component-per-file": "off", + "vue/html-closing-bracket-newline": "off", + "vue/max-attributes-per-line": "off", + "vue/multiline-html-element-content-newline": "off", + "vue/singleline-html-element-content-newline": "off", + "vue/attribute-hyphenation": "off", + // "vue/html-self-closing": "off", + "vue/require-default-prop": "off", + "vue/html-self-closing": [ + "error", + { + html: { + void: "always", + normal: "never", + component: "always" + }, + svg: "always", + math: "always" + } + ] + } }; diff --git a/package.json b/package.json index e2f0129..8944dd4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "front-next", - "version": "0.3.0", + "version": "0.3.1", "scripts": { "dev": "vite", "build": "vue-tsc --noEmit --skipLibCheck && vite build", @@ -11,13 +11,13 @@ "dependencies": { "array.prototype.flat": "^1.2.4", "axios": "^0.21.1", - "cl-admin-crud-vue3": "^0.1.3", + "cl-admin-crud-vue3": "^0.1.6", "clipboard": "^2.0.8", "clone-deep": "^4.0.1", "codemirror": "^5.60.0", "core-js": "^3.6.5", "echarts": "^5.0.2", - "element-plus": "1.0.2-beta.35", + "element-plus": "^1.0.2-beta.45", "file-saver": "^2.0.5", "glob": "^7.1.6", "js-beautify": "^1.13.5", @@ -50,11 +50,11 @@ "eslint-plugin-prettier": "^3.3.1", "eslint-plugin-vue": "^7.8.0", "prettier": "^2.2.1", - "sass": "^1.32.8", - "sass-loader": "^11.0.1", + "sass": "^1.34.0", + "sass-loader": "^11.1.1", "svg-sprite-loader": "^6.0.2", "typescript": "^4.1.3", - "vite": "^2.1.5", + "vite": "^2.3.5", "vite-plugin-style-import": "^0.9.1", "vite-svg-loader": "^1.5.1", "vue-tsc": "^0.0.8" diff --git a/src/cool/modules/task/views/task.vue b/src/cool/modules/task/views/task.vue index 004d65e..f009470 100644 --- a/src/cool/modules/task/views/task.vue +++ b/src/cool/modules/task/views/task.vue @@ -216,7 +216,7 @@