File tree
Expand file treeCollapse file tree1 file changed
+5
-1
lines changed Expand file treeCollapse file tree1 file changed
+5
-1
lines changed Original file line number | Diff line number | Diff line change |
---|
@@ -8,6 +8,10 @@ function posixify(file) {
|
8 | 8 | return file.replace(/[/\\]/g, '/');
|
9 | 9 | }
|
10 | 10 |
|
| 11 | +function interopEsmDefault(mod) { |
| 12 | +return mod && mod.__esModule && mod.default ? mod.default : mod; |
| 13 | +} |
| 14 | + |
11 | 15 | const virtualModules = new Map();
|
12 | 16 | let index = 0;
|
13 | 17 |
|
@@ -26,7 +30,7 @@ for (let i = 0; i < process.argv.length; i++) {
|
26 | 30 |
|
27 | 31 | try {
|
28 | 32 | const configPath = path.resolve(process.cwd(), configFile);
|
29 |
| -const config = require(configPath); |
| 33 | +const config = interopEsmDefault(require(configPath)); |
30 | 34 | let found = false;
|
31 | 35 | if (Array.isArray(config)) {
|
32 | 36 | found = config.some(check);
|
|
You can’t perform that action at this time.
0 commit comments