diff --git a/scripts/generate-supported-browsers.mjs b/scripts/generate-supported-browsers.mjs index 2f8b627c57d..adff4d0bf2a 100644 --- a/scripts/generate-supported-browsers.mjs +++ b/scripts/generate-supported-browsers.mjs @@ -1,17 +1,25 @@ -import { getUserAgentRegex } from 'browserslist-useragent-regexp'; -import fs from 'fs'; -import path from 'path'; -import { fileURLToPath } from 'url'; +import { getUserAgentRegex } from "browserslist-useragent-regexp"; +import fs from "fs"; +import path from "path"; +import { fileURLToPath } from "url"; const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); const regex = getUserAgentRegex({ - ignoreMinor: true, - ignorePatch: true, - allowZeroSubversions: false, - allowHigherVersions: true, + ignoreMinor: true, + ignorePatch: true, + allowZeroSubversions: false, + allowHigherVersions: true, }); -const supportedBrowsersPath = path.resolve(__dirname, '../src/supportedBrowsers.ts'); -fs.writeFileSync(supportedBrowsersPath, `export default ${regex};`); +const supportedBrowsersPath = path.resolve( + __dirname, + "../src/supportedBrowsers.ts", +); +fs.writeFileSync( + supportedBrowsersPath, + `/* eslint-disable */ +export default ${regex}; +`, +); diff --git a/scripts/setup-care-apps.ts b/scripts/setup-care-apps.ts index 714d12f5a5a..300a1f1d7c1 100644 --- a/scripts/setup-care-apps.ts +++ b/scripts/setup-care-apps.ts @@ -86,7 +86,8 @@ const plugins = readAppsConfig(); // Generate pluginMap.ts const pluginMapPath = path.join(__dirname, "..", "src", "pluginMap.ts"); -const pluginMapContent = `// Use type assertion for the static import\n${plugins +const pluginMapContent = `/* eslint-disable */ +// Use type assertion for the static import\n${plugins .map( (plugin) => `// @ts-expect-error Remote module will be available at runtime\nimport ${plugin.camelCaseName}Manifest from "${plugin.repo}/manifest";`, diff --git a/vite.config.mts b/vite.config.mts index e47ffd0a21b..4d49e090a74 100644 --- a/vite.config.mts +++ b/vite.config.mts @@ -209,7 +209,12 @@ export default defineConfig(({ mode }) => { ], }), react(), - checker({ typescript: true }), + checker({ + typescript: true, + eslint: { + lintCommand: "eslint ./src", + }, + }), treeShakeCareIcons({ iconWhitelist: ["default"], }),