Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
mishankov committed Oct 1, 2024
1 parent c6dedb4 commit a44c2fb
Showing 1 changed file with 62 additions and 57 deletions.
119 changes: 62 additions & 57 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,68 +1,73 @@
import typescriptEslint from "@typescript-eslint/eslint-plugin";
import globals from "globals";
import tsParser from "@typescript-eslint/parser";
import parser from "svelte-eslint-parser";
import path from "node:path";
import { fileURLToPath } from "node:url";
import js from "@eslint/js";
import { FlatCompat } from "@eslint/eslintrc";
import typescriptEslint from '@typescript-eslint/eslint-plugin';
import globals from 'globals';
import tsParser from '@typescript-eslint/parser';
import parser from 'svelte-eslint-parser';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import js from '@eslint/js';
import { FlatCompat } from '@eslint/eslintrc';

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
allConfig: js.configs.all
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
allConfig: js.configs.all
});

export default [{
ignores: [
"**/.DS_Store",
"**/node_modules",
"build",
".svelte-kit",
"package",
"**/.env",
"**/.env.*",
"!**/.env.example",
"**/pnpm-lock.yaml",
"**/package-lock.json",
"**/yarn.lock",
],
}, ...compat.extends(
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:svelte/recommended",
"prettier",
), {
plugins: {
"@typescript-eslint": typescriptEslint,
},
export default [
{
ignores: [
'**/.DS_Store',
'**/node_modules',
'build',
'.svelte-kit',
'package',
'**/.env',
'**/.env.*',
'!**/.env.example',
'**/pnpm-lock.yaml',
'**/package-lock.json',
'**/yarn.lock'
]
},
...compat.extends(
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:svelte/recommended',
'prettier'
),
{
plugins: {
'@typescript-eslint': typescriptEslint
},

languageOptions: {
globals: {
...globals.browser,
...globals.node,
},
languageOptions: {
globals: {
...globals.browser,
...globals.node
},

parser: tsParser,
ecmaVersion: 2020,
sourceType: "module",
parser: tsParser,
ecmaVersion: 2020,
sourceType: 'module',

parserOptions: {
extraFileExtensions: [".svelte"],
},
},
}, {
files: ["**/*.svelte"],
parserOptions: {
extraFileExtensions: ['.svelte']
}
}
},
{
files: ['**/*.svelte'],

languageOptions: {
parser: parser,
ecmaVersion: 5,
sourceType: "script",
languageOptions: {
parser: parser,
ecmaVersion: 5,
sourceType: 'script',

parserOptions: {
parser: "@typescript-eslint/parser",
},
},
}];
parserOptions: {
parser: '@typescript-eslint/parser'
}
}
}
];

0 comments on commit a44c2fb

Please sign in to comment.