generated from Seekra/repository-template
feat(lint): add ESLint rules
Added some ESLint rules (see eslint.config.js).
This commit is contained in:
@@ -13,6 +13,38 @@ export default defineConfig([
|
|||||||
...globals.browser,
|
...globals.browser,
|
||||||
...globals.node
|
...globals.node
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
rules: {
|
||||||
|
'eqeqeq': 'error',
|
||||||
|
|
||||||
|
'no-unused-vars': 'error',
|
||||||
|
'no-undef': 'error',
|
||||||
|
'prefer-const': 'error',
|
||||||
|
'no-var': 'error',
|
||||||
|
'no-duplicate-imports': 'error',
|
||||||
|
'no-import-assign': 'error',
|
||||||
|
|
||||||
|
'no-empty-function': 'error',
|
||||||
|
'default-param-last': 'error',
|
||||||
|
'prefer-arrow-callback': 'error',
|
||||||
|
'require-await': 'warn',
|
||||||
|
'no-async-promise-executor': 'error',
|
||||||
|
|
||||||
|
'no-unreachable': 'error',
|
||||||
|
|
||||||
|
'no-constant-condition': 'error',
|
||||||
|
|
||||||
|
'no-debugger': 'error',
|
||||||
|
'no-alert': 'error',
|
||||||
|
'no-console': 'warn',
|
||||||
|
|
||||||
|
'no-new-object': 'error',
|
||||||
|
'no-array-constructor': 'error',
|
||||||
|
'no-prototype-builtins': 'error',
|
||||||
|
'object-shorthand': 'error',
|
||||||
|
|
||||||
|
'prefer-template': 'error',
|
||||||
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
pluginVue.configs['flat/essential'],
|
pluginVue.configs['flat/essential'],
|
||||||
|
|||||||
Reference in New Issue
Block a user