mirror of
https://github.com/immich-app/immich.git
synced 2025-12-18 01:11:07 +03:00
chore: bump browserlists version and load tscompat browserlist from file (#19212)
* chore: bump browserlists version to include latest edge browsers * chore: load tscompat browser list from the .browserslistrc file
This commit is contained in:
@@ -4,6 +4,7 @@ import eslintPluginCompat from 'eslint-plugin-compat';
|
||||
import eslintPluginSvelte from 'eslint-plugin-svelte';
|
||||
import eslintPluginUnicorn from 'eslint-plugin-unicorn';
|
||||
import globals from 'globals';
|
||||
import fs from 'node:fs';
|
||||
import path from 'node:path';
|
||||
import { fileURLToPath } from 'node:url';
|
||||
import parser from 'svelte-eslint-parser';
|
||||
@@ -23,7 +24,13 @@ export default typescriptEslint.config(
|
||||
rules: {
|
||||
'tscompat/tscompat': [
|
||||
'error',
|
||||
{ browserslist: ['> 0.2% and last 4 major versions', '> 0.5%', 'not dead', 'edge >= 135', 'not edge < 135'] },
|
||||
{
|
||||
browserslist: fs
|
||||
.readFileSync(path.join(__dirname, '.browserslistrc'), 'utf8')
|
||||
.split('\n')
|
||||
.map((line) => line.trim())
|
||||
.filter((line) => line && !line.startsWith('#')),
|
||||
},
|
||||
],
|
||||
},
|
||||
languageOptions: {
|
||||
|
||||
Reference in New Issue
Block a user