diff --git a/.eslintrc.yml b/.eslintrc.yml index 2c39435f3..271427fe3 100644 --- a/.eslintrc.yml +++ b/.eslintrc.yml @@ -9,3 +9,12 @@ extends: - "plugin:vue/strongly-recommended" - "plugin:vue/recommended" - prettier + +globals: + OC: + t: + +rules: + no-plusplus: + - error + - allowForLoopAfterthoughts: true diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 9df24b78c..7ca74a038 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -47,6 +47,16 @@ jobs: Please run `npm run prettier-fix` in order to correct this.'; exit 1; } + + - name: Check for issues with vue and js files (eslint) + shell: bash + run: >- + npm run eslint || { + echo '::error ::The eslint style checker failed. + Please run `npm run eslint-fix` in order to correct this.'; + exit 1; + } + - name: Check for formatting issues with CSS files (stylelint) shell: bash run: >- diff --git a/CHANGELOG.md b/CHANGELOG.md index 36688b009..561248e23 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,8 @@ [#607](https://github.com/nextcloud/cookbook/pull/607) @christianlupus - Enforce CSS styling using stylelint [#608](https://github.com/nextcloud/cookbook/pull/608) @christianlupus +- More code styling, cleanup & minor bugfixes + [#615](https://github.com/nextcloud/cookbook/pull/615) @seyfeb ## Deprecated - Obsolete routes to old user interface, see `appinfo/routes.php` diff --git a/src/components/AppControls.vue b/src/components/AppControls.vue index f1aeddaa5..39fcc5705 100644 --- a/src/components/AppControls.vue +++ b/src/components/AppControls.vue @@ -1,30 +1,30 @@ @@ -19,11 +23,10 @@ export default { } }, methods: { - toggleCollapsed: function () { + toggleCollapsed() { this.collapsed = !this.collapsed }, }, - mounted() {}, } diff --git a/src/components/RecipeIngredient.vue b/src/components/RecipeIngredient.vue index b599eac95..5aa6759e1 100644 --- a/src/components/RecipeIngredient.vue +++ b/src/components/RecipeIngredient.vue @@ -7,6 +7,7 @@ @click="toggleDone" >
+
@@ -14,7 +15,15 @@ diff --git a/src/components/RecipeTimer.vue b/src/components/RecipeTimer.vue index 2bf9ab6d0..375a9dcb8 100644 --- a/src/components/RecipeTimer.vue +++ b/src/components/RecipeTimer.vue @@ -1,7 +1,7 @@