Files
lingji-work-fe/.eslintrc.cjs
2025-06-25 18:26:03 +08:00

43 lines
1.1 KiB
JavaScript

/*
* @Author: RenXiaoDong
* @Date: 2025-06-24 16:29:10
*/
/* eslint-env node */
// eslint-disable-next-line @typescript-eslint/no-require-imports
require('@rushstack/eslint-patch/modern-module-resolution');
module.exports = {
root: true,
extends: [
'plugin:vue/vue3-recommended',
'eslint:recommended',
'@vue/eslint-config-typescript',
'@vue/eslint-config-prettier',
'alloy',
'alloy/vue',
'alloy/typescript',
'./config/unplugin/.eslintrc-auto-import.json',
],
parser: 'vue-eslint-parser',
parserOptions: {
ecmaVersion: 'latest',
parser: {
js: '@babel/eslint-parser',
jsx: '@babel/eslint-parser',
ts: '@typescript-eslint/parser',
tsx: '@typescript-eslint/parser',
},
},
rules: {
'@typescript-eslint/prefer-optional-chain': 'off',
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'prettier/prettier': ['error', { endOfLine: 'auto' }],
'vue/no-duplicate-attributes': 'off',
'vue/v-on-event-hyphenation': 'off',
},
globals: {
defineOptions: 'readonly',
},
};