From 1c004cbd17b956ed2f6ddf151d06daf7159dc0ad Mon Sep 17 00:00:00 2001 From: Pavel Djundik Date: Wed, 30 Sep 2020 17:44:07 +0300 Subject: [PATCH] Upgrade eslint-plugin-vue and fix rules --- .eslintrc.yml | 10 +++++++++- client/components/JoinChannel.vue | 4 ++-- client/components/LinkPreviewToggle.vue | 2 +- client/components/MessageList.vue | 2 +- client/components/NetworkList.vue | 4 ++-- client/components/NetworkLobby.vue | 2 +- package.json | 2 +- yarn.lock | 15 ++++++++------- 8 files changed, 25 insertions(+), 16 deletions(-) diff --git a/.eslintrc.yml b/.eslintrc.yml index 251c77ec..b67991b5 100644 --- a/.eslintrc.yml +++ b/.eslintrc.yml @@ -55,8 +55,16 @@ rules: spaced-comment: [error, always] strict: off yoda: error - vue/require-default-prop: off + vue/component-tags-order: + - error + - order: + - template + - style + - script + vue/no-mutating-props: off vue/no-v-html: off + vue/require-default-prop: off + vue/v-slot-style: [error, longform] plugins: - vue diff --git a/client/components/JoinChannel.vue b/client/components/JoinChannel.vue index f18ca848..129d5383 100644 --- a/client/components/JoinChannel.vue +++ b/client/components/JoinChannel.vue @@ -5,7 +5,7 @@ method="post" action="" autocomplete="off" - @keydown.esc.prevent="$emit('toggleJoinChannel')" + @keydown.esc.prevent="$emit('toggle-join-channel')" @submit.prevent="onSubmit" > diff --git a/client/components/NetworkList.vue b/client/components/NetworkList.vue index c9b79921..607f3752 100644 --- a/client/components/NetworkList.vue +++ b/client/components/NetworkList.vue @@ -82,13 +82,13 @@ $store.state.activeChannel && network.channels[0] === $store.state.activeChannel.channel " - @toggleJoinChannel="network.isJoinChannelShown = !network.isJoinChannelShown" + @toggle-join-channel="network.isJoinChannelShown = !network.isJoinChannelShown" /> diff --git a/package.json b/package.json index 30a6be34..ce04a49b 100644 --- a/package.json +++ b/package.json @@ -86,7 +86,7 @@ "emoji-regex": "9.0.0", "eslint": "7.10.0", "eslint-config-prettier": "6.12.0", - "eslint-plugin-vue": "6.2.2", + "eslint-plugin-vue": "7.0.0", "fuzzy": "0.1.3", "husky": "4.3.0", "mini-css-extract-plugin": "0.11.2", diff --git a/yarn.lock b/yarn.lock index 87a0c5fb..b912a582 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3383,14 +3383,15 @@ eslint-config-prettier@6.12.0: dependencies: get-stdin "^6.0.0" -eslint-plugin-vue@6.2.2: - version "6.2.2" - resolved "https://registry.yarnpkg.com/eslint-plugin-vue/-/eslint-plugin-vue-6.2.2.tgz#27fecd9a3a24789b0f111ecdd540a9e56198e0fe" - integrity sha512-Nhc+oVAHm0uz/PkJAWscwIT4ijTrK5fqNqz9QB1D35SbbuMG1uB6Yr5AJpvPSWg+WOw7nYNswerYh0kOk64gqQ== +eslint-plugin-vue@7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-vue/-/eslint-plugin-vue-7.0.0.tgz#abaf59dec3aa50228b37a89ca1239893c96c981f" + integrity sha512-SFcM8ZMdVRUQKrAryl6Q5razrJtloATUOKTZoK/8yvQig1c1L3VRoMLL9AXiV3VNsKXolkk6yeMIiqGf33/Iew== dependencies: + eslint-utils "^2.1.0" natural-compare "^1.4.0" - semver "^5.6.0" - vue-eslint-parser "^7.0.0" + semver "^7.3.2" + vue-eslint-parser "^7.1.0" eslint-scope@^4.0.3: version "4.0.3" @@ -9585,7 +9586,7 @@ vm-browserify@^1.0.1: resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-1.1.2.tgz#78641c488b8e6ca91a75f511e7a3b32a86e5dda0" integrity sha512-2ham8XPWTONajOR0ohOKOHXkm3+gaBmGut3SRuu75xLd/RRaY6vqgh8NBYYk7+RW3u5AtzPQZG8F10LHkl0lAQ== -vue-eslint-parser@^7.0.0: +vue-eslint-parser@^7.1.0: version "7.1.0" resolved "https://registry.yarnpkg.com/vue-eslint-parser/-/vue-eslint-parser-7.1.0.tgz#9cdbcc823e656b087507a1911732b867ac101e83" integrity sha512-Kr21uPfthDc63nDl27AGQEhtt9VrZ9nkYk/NTftJ2ws9XiJwzJJCnCr3AITQ2jpRMA0XPGDECxYH8E027qMK9Q==