UNPKG

@boehringer-ingelheim/eslint-config

Version:

Shared eslint configuration used at Boehringer Ingelheim for code styling

34 lines 1.85 kB
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); const eslint_plugin_playwright_1 = __importDefault(require("eslint-plugin-playwright")); const config_1 = require("eslint/config"); const playwrightPlugin = eslint_plugin_playwright_1.default; exports.default = (0, config_1.defineConfig)({ ...playwrightPlugin.configs['flat/recommended'], rules: { /** * At the moment, `eslint-plugin-playwright` does not fully support component testing with type information. * https://github.com/playwright-community/eslint-plugin-playwright/issues/298 * * The `mount` function is flagged as an error by the `@typescript-eslint/unbound-method` rule. * But it is okay to use `mount` in this context for test files. * https://typescript-eslint.io/rules/unbound-method/#when-not-to-use-it * * Hint: `eslint-plugin-jest` has already a customized version of this rule. * https://github.com/jest-community/eslint-plugin-jest/blob/main/docs/rules/unbound-method.md */ '@typescript-eslint/unbound-method': 'off', // eslint-plugin-playwright: https://github.com/playwright-community/eslint-plugin-playwright ...playwrightPlugin.configs['flat/recommended'].rules, 'playwright/prefer-to-be': 'error', 'playwright/prefer-to-have-length': 'error', 'playwright/require-top-level-describe': 'error', // eslint-plugin-sonarjs: https://github.com/SonarSource/SonarJS/blob/master/packages/analysis/src/jsts/rules/README.md 'sonarjs/no-duplicate-string': 'off', 'sonarjs/slow-regex': 'off', }, }); //# sourceMappingURL=playwright.js.map