summaryrefslogblamecommitdiffstatshomepage
path: root/frontend/.eslintrc.cjs
blob: c204ebe45de1cf5ba8e3da6627b0e50378cc5bb4 (plain) (tree)
















































                                                                                      
module.exports = {
	root: true,
	extends: [
		'eslint:recommended',
		'plugin:@typescript-eslint/recommended-type-checked',
		'plugin:@typescript-eslint/stylistic-type-checked',
		'plugin:svelte/recommended',
		'prettier'
	],
	parser: '@typescript-eslint/parser',
	plugins: ['@typescript-eslint'],
	ignorePatterns: ['*.cjs'],
	parserOptions: {
		sourceType: 'module',
		ecmaVersion: 2022,
		extraFileExtensions: ['.svelte'],
		project: true,
		tsconfigRootDir: __dirname
	},
	env: {
		browser: true,
		es2022: true,
		node: true
	},
	overrides: [
		{
			files: ['*.svelte'],
			parser: 'svelte-eslint-parser',
			parserOptions: {
				parser: '@typescript-eslint/parser'
			},
			rules: {
				'@typescript-eslint/no-unsafe-argument': 'off',
				'@typescript-eslint/no-unsafe-assignment': 'off',
				'@typescript-eslint/no-unsafe-call': 'off',
				'@typescript-eslint/no-unsafe-enum-comparison': 'off',
				'@typescript-eslint/no-unsafe-member-access': 'off'
			}
		},
		{
			files: ['codegen.ts', 'svelte.config.js'],
			extends: ['plugin:@typescript-eslint/disable-type-checked']
		}
	],
	rules: {
		'no-console': 'warn',
		eqeqeq: 'error'
	}
};