From ed36577de1b42b0f6c8177ac531f64f9cdb3a3d4 Mon Sep 17 00:00:00 2001 From: Eric Lindell Date: Wed, 23 Oct 2024 23:57:08 +0200 Subject: [PATCH] fix(eslint-plugin): let no-unsupported-configs rule check in next.config.ts|mts|cts --- .../src/rules/no-unsupported-configs.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/eslint-plugin-next-on-pages/src/rules/no-unsupported-configs.ts b/packages/eslint-plugin-next-on-pages/src/rules/no-unsupported-configs.ts index 55565fce8..4d471ac0a 100644 --- a/packages/eslint-plugin-next-on-pages/src/rules/no-unsupported-configs.ts +++ b/packages/eslint-plugin-next-on-pages/src/rules/no-unsupported-configs.ts @@ -97,7 +97,7 @@ const ruleSchema = { const rule: Rule.RuleModule = { create: context => { const code = context.sourceCode; - const exportedConfigName = context.filename.match(/next\.config\.m?js$/) + const exportedConfigName = context.filename.match(/next\.config\.(js|cjs|mjs|ts|cts|mts)$/) ? getConfigVariableName(code) : null;