Files
lingji-work-fe/.eslintrc.cjs

51 lines
1.3 KiB
JavaScript
Raw Normal View History

2025-06-25 18:26:03 +08:00
/*
* @Author: RenXiaoDong
* @Date: 2025-06-24 16:29:10
*/
2025-06-16 14:42:26 +08:00
/* 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',
},
},
babelOptions: {
presets: [
'@babel/preset-env'
],
plugins: [
'@vue/babel-plugin-jsx'
]
},
2025-06-16 14:42:26 +08:00
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' }],
2025-06-25 18:26:03 +08:00
'vue/no-duplicate-attributes': 'off',
'vue/v-on-event-hyphenation': 'off',
2025-06-16 14:42:26 +08:00
},
globals: {
defineOptions: 'readonly',
},
};