From e8f3c784b338a87a274dce44c73230d621cecb62 Mon Sep 17 00:00:00 2001 From: Eren Bets <0x142857@gmail.com> Date: Mon, 15 Mar 2021 23:02:58 +0800 Subject: [PATCH] fix: correctly handle explicit ts config file (#2515) --- packages/vite/src/node/config.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/vite/src/node/config.ts b/packages/vite/src/node/config.ts index b9118ead5b2567..8f77473d38a655 100644 --- a/packages/vite/src/node/config.ts +++ b/packages/vite/src/node/config.ts @@ -611,6 +611,7 @@ export async function loadConfigFromFile( if (configFile) { // explicit config path is always resolved from cwd resolvedPath = path.resolve(configFile) + isTS = configFile.endsWith('.ts') } else { // implicit config file loaded from inline root (if present) // otherwise from cwd