From 5a91ffb1675e57cb9a2ac76d47e064ec78b41552 Mon Sep 17 00:00:00 2001 From: JounQin Date: Sun, 10 Dec 2023 22:58:08 +0800 Subject: [PATCH] fix(eslint): incorrect project setting for ts in md/mdx --- packages/eslint-config/overrides.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/packages/eslint-config/overrides.js b/packages/eslint-config/overrides.js index 7353a01b..3c54ff20 100644 --- a/packages/eslint-config/overrides.js +++ b/packages/eslint-config/overrides.js @@ -224,8 +224,14 @@ exports.ts = [ }, }, { - files: ['*.cts', '*.mts', '*.ts', '*.tsx'], - excludedFiles: ['*.d.cts', '*.d.mts', '*.d.ts'], + files: '**/*.{md,mdx}/**/*.{cts,mts,ts,tsx}', + parserOptions: { + project: null, + }, + }, + { + files: '*.{cts,mts,ts,tsx}', + excludedFiles: ['**/*.{md,mdx}/**/*.{cts,mts,ts,tsx}', '*.d.{cts,mts,ts}'], extends: ['plugin:@typescript-eslint/recommended-requiring-type-checking'], rules: { '@typescript-eslint/no-floating-promises': [