From 466246e65033c903b7c878c37444a187ec1db72a Mon Sep 17 00:00:00 2001 From: Nancy Butler <42977925+mantis-toboggan-md@users.noreply.github.com> Date: Tue, 3 Dec 2024 14:16:32 -0800 Subject: [PATCH 1/4] fix eslint and remove remaining ts references --- .eslintrc.js | 45 ++++----- package.json | 16 +++- pkg/capi/components/AutoImport.vue | 5 +- pkg/capi/components/CCVariables/Variable.vue | 46 ++++++---- pkg/capi/components/CCVariables/index.vue | 63 +++++++------ pkg/capi/components/CardGrid.vue | 20 ++-- .../components/ClusterClassCard/index.vue | 12 +-- pkg/capi/components/ClusterListBanner.vue | 8 +- pkg/capi/components/ExperimentalBanner.vue | 9 +- .../ClusterConfig.vue | 91 +++++++++---------- .../ControlPlaneEndpointSection.vue | 6 +- .../NetworkSection.vue | 6 +- .../cluster.x-k8s.io.cluster/WorkerItem.vue | 16 ++-- .../edit/cluster.x-k8s.io.cluster/index.vue | 14 +-- .../ProviderConfig.vue | 45 +++++---- .../index.vue | 31 ++----- pkg/capi/tsconfig.json | 2 - yarn.lock | 38 +++++++- 18 files changed, 252 insertions(+), 221 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index b8f0dc0..027d7c1 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -8,31 +8,32 @@ module.exports = { extends: [ 'standard', 'eslint:recommended', - '@nuxtjs/eslint-config-typescript', - 'plugin:cypress/recommended' + // '@nuxtjs/eslint-config-typescript', + 'plugin:cypress/recommended', + 'plugin:vue/vue3-recommended', ], // add your custom rules here rules: { - 'dot-notation': 'off', - 'generator-star-spacing': 'off', - 'guard-for-in': 'off', - 'linebreak-style': 'off', - 'new-cap': 'off', - 'no-empty': 'off', - 'no-extra-boolean-cast': 'off', - 'no-new': 'off', - 'no-plusplus': 'off', - 'no-useless-escape': 'off', - 'nuxt/no-cjs-in-config': 'off', - 'semi-spacing': 'off', - 'space-in-parens': 'off', - strict: 'off', - 'unicorn/no-new-buffer': 'off', - 'vue/html-self-closing': 'off', - 'vue/no-unused-components': 'warn', - 'vue/no-v-html': 'off', - 'wrap-iife': 'off', - 'vue/no-v-for-template-key': 'off', + 'dot-notation': 'off', + 'generator-star-spacing': 'off', + 'guard-for-in': 'off', + 'linebreak-style': 'off', + 'new-cap': 'off', + 'no-empty': 'off', + 'no-extra-boolean-cast': 'off', + 'no-new': 'off', + 'no-plusplus': 'off', + 'no-useless-escape': 'off', + 'nuxt/no-cjs-in-config': 'off', + 'semi-spacing': 'off', + 'space-in-parens': 'off', + strict: 'off', + 'unicorn/no-new-buffer': 'off', + 'vue/html-self-closing': 'off', + 'vue/no-unused-components': 'warn', + 'vue/no-v-html': 'off', + 'wrap-iife': 'off', + 'vue/no-v-for-template-key': 'off', 'array-bracket-spacing': 'warn', 'arrow-parens': 'warn', 'arrow-spacing': ['warn', { before: true, after: true }], diff --git a/package.json b/package.json index 801cc12..58b2e7e 100644 --- a/package.json +++ b/package.json @@ -10,12 +10,12 @@ "@rancher/components": "^0.3.0-alpha.1", "@rancher/shell": "3.0.0", "@types/lodash": "4.14.196", - "core-js": "3.21.1", - "css-loader": "6.7.3", - "node-polyfill-webpack-plugin": "^3.0.0", "cache-loader": "^4.1.0", "color": "4.2.3", - "ip": "2.0.1" + "core-js": "3.21.1", + "css-loader": "6.7.3", + "ip": "2.0.1", + "node-polyfill-webpack-plugin": "^3.0.0" }, "resolutions": { "**/webpack": "5", @@ -31,5 +31,13 @@ "publish-pkgs": "./node_modules/@rancher/shell/scripts/extension/publish", "parse-tag-name": "./node_modules/@rancher/shell/scripts/extension/parse-tag-name", "migrate": "node ./scrips/vue-migrate.js" + }, + "devDependencies": { + "eslint-plugin-cypress": "2.12.1", + "eslint-plugin-import": "2.23.4", + "eslint-plugin-jest": "24.4.0", + "eslint-plugin-node": "11.1.0", + "eslint-plugin-promise": "7.2.1", + "eslint-plugin-vue": "9.10.0" } } diff --git a/pkg/capi/components/AutoImport.vue b/pkg/capi/components/AutoImport.vue index 2e55f61..97434cd 100644 --- a/pkg/capi/components/AutoImport.vue +++ b/pkg/capi/components/AutoImport.vue @@ -1,9 +1,8 @@