diff --git a/.github/workflows/lint-build-test.yml b/.github/workflows/lint-build-test.yml index 70ac9fe5cb7..635ffa1a336 100644 --- a/.github/workflows/lint-build-test.yml +++ b/.github/workflows/lint-build-test.yml @@ -39,6 +39,10 @@ jobs: is-high-risk-environment: false node-version: ${{ matrix.node-version }} - run: yarn lint + env: + # Optimize Node.js memory for ESLint performance in large monorepos + # See: https://typescript-eslint.io/troubleshooting/typed-linting/performance + NODE_OPTIONS: '--max-semi-space-size=256 --max-old-space-size=8192' - name: Require clean working directory shell: bash run: | diff --git a/eslint.config.mjs b/eslint.config.mjs index a124c6f9948..e808f9ad094 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -28,6 +28,12 @@ const config = createConfig([ // Enabling it with error suppression breaks `--fix`, because the autofixer for this rule // does not work very well. 'jsdoc/require-jsdoc': 'off', + // Performance optimizations for large monorepos + // See: https://typescript-eslint.io/troubleshooting/typed-linting/performance + // Prettier runs separately via `yarn lint:misc`, no need to run through ESLint (~30% savings) + // 'prettier/prettier': 'off', + // This rule is very expensive (~22% of lint time) and provides limited value + // 'import-x/namespace': 'off', }, settings: { jsdoc: {