Skip to content

Commit c2360fc

Browse files
fiskerAriPerkkio
andauthored
fix: config load on Windows (#538)
* fix: fix config load on Windows * fix: formatting --------- Co-authored-by: Ari Perkkiö <[email protected]>
1 parent 9a905c4 commit c2360fc

File tree

1 file changed

+3
-1
lines changed
  • packages/eslint-remote-tester/src/config

1 file changed

+3
-1
lines changed

packages/eslint-remote-tester/src/config/load.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import { pathToFileURL } from 'node:url';
2+
13
/** @internal */
24
export const loadTSConfig = async (configPath: string) => {
35
let importx: typeof import('importx') | undefined = undefined;
@@ -37,6 +39,6 @@ export const loadConfig = async (configPath: string) => {
3739
return loadTSConfig(configPath);
3840
}
3941

40-
const { default: config } = await import(configPath);
42+
const { default: config } = await import(pathToFileURL(configPath).href);
4143
return config;
4244
};

0 commit comments

Comments
 (0)