forked from GlobalHive/vuejs-tour
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.eslintrc.js
More file actions
48 lines (48 loc) · 1.28 KB
/
Copy path.eslintrc.js
File metadata and controls
48 lines (48 loc) · 1.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
module.exports = {
root: true,
env: {
node: true,
browser: true,
},
extends: [
'plugin:vue/vue3-recommended',
'@vue/eslint-config-typescript/recommended',
'@vue/eslint-config-prettier',
],
parserOptions: {
ecmaVersion: 2020,
project: ['./tsconfig.json', './tsconfig.node.json'],
},
rules: {
// Allow unused parameters in TypeScript interfaces and type definitions
'@typescript-eslint/no-unused-vars': [
'warn',
{
argsIgnorePattern: '^_',
varsIgnorePattern: '^_',
// Ignore interface and type declaration parameters
args: 'none',
},
],
},
overrides: [
{
files: ['src/Types.ts'],
rules: {
// Disable unused vars completely for Types.ts since interface parameter names are for documentation
'@typescript-eslint/no-unused-vars': 'off',
},
},
{
files: ['*.config.ts', '*.config.js'],
rules: {
// Allow any type assertions in config files
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/no-unsafe-call': 'off',
'@typescript-eslint/no-unsafe-member-access': 'off',
'@typescript-eslint/no-unsafe-assignment': 'off',
},
},
],
};