Skip to content

Commit d735b33

Browse files
committed
resolve load config file"
1 parent a4bc638 commit d735b33

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

lib/config.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,12 @@ async function loadConfigFile(configFile) {
259259
}
260260
} else {
261261
// Try ESM import first for JS files
262-
configModule = await import(configFile)
262+
const resolvedImportPath =
263+
isWindows() && typeof configFile === 'string' && path.isAbsolute(configFile)
264+
? pathToFileURL(configFile).href
265+
: configFile
266+
267+
configModule = await import(resolvedImportPath)
263268
}
264269
} catch (importError) {
265270
try {

0 commit comments

Comments
 (0)