-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy patheslint.config.mjs
More file actions
28 lines (27 loc) · 1.04 KB
/
Copy patheslint.config.mjs
File metadata and controls
28 lines (27 loc) · 1.04 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
import js from '@eslint/js';
import globals from 'globals';
import tseslint from 'typescript-eslint';
import { defineConfig } from 'eslint/config';
import perfectionist from 'eslint-plugin-perfectionist';
import prettierPlugin from 'eslint-plugin-prettier';
export default defineConfig([
{
files: ['**/*.{js,mjs,cjs,ts,mts,cts,tsx}'],
plugins: { js, perfectionist, prettierPlugin },
extends: ['js/recommended'],
languageOptions: { globals: { ...globals.browser, ...globals.node } },
rules: {
'no-console': 1,
semi: ['error', 'always'],
'quote-props': ['error', 'as-needed'],
'@typescript-eslint/no-non-null-assertion': 'warn',
'@typescript-eslint/no-explicit-any': 'warn',
'perfectionist/sort-union-types': 'error',
},
},
tseslint.configs.recommended,
{
// skrapa.d.ts is generated and overwritten by skrapa on every run.
ignores: ['dist/**/*', 'node_modules/**/*', '.skrapa/**/*', 'skrapa.d.ts'],
},
]);