lint: Enable 'prefer-const' rule

Now that all code conforms with the rule, we can enforce it to make
sure we stick to it with new code.

Relax the rule for destructuring, so we don't have to jump through
hoops to avoid "mixed" assignments.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell-extensions/-/merge_requests/432>
This commit is contained in:
Florian Müllner
2025-10-26 13:22:31 +01:00
committed by Marge Bot
parent 57b7f526df
commit 93eac46b1d
+3
View File
@@ -20,6 +20,9 @@ export default defineConfig([
afterColon: true,
}],
'prefer-arrow-callback': 'error',
'prefer-const': ['error', {
destructuring: 'all',
}],
'jsdoc/require-param-description': 'off',
'jsdoc/require-jsdoc': ['error', {
exemptEmptyFunctions: true,