File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
packages/cli-plugin-metro/src/tools Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -92,10 +92,11 @@ export default async function loadMetroConfig(
92
92
overrideConfig . reporter = options . reporter ;
93
93
}
94
94
95
- const projectConfig = await resolveConfig ( undefined , ctx . root ) ;
95
+ const cwd = ctx . root ;
96
+ const projectConfig = await resolveConfig ( options . config , cwd ) ;
96
97
97
98
if ( projectConfig . isEmpty ) {
98
- throw new CLIError ( `No metro config found in ${ ctx . root } ` ) ;
99
+ throw new CLIError ( `No Metro config found in ${ cwd } ` ) ;
99
100
}
100
101
101
102
logger . debug ( `Reading Metro config from ${ projectConfig . filepath } ` ) ;
@@ -119,7 +120,10 @@ This warning will be removed in future (https://github.com/facebook/metro/issues
119
120
}
120
121
121
122
return mergeConfig (
122
- await loadConfig ( { cwd : ctx . root , ...options } ) ,
123
+ await loadConfig ( {
124
+ cwd,
125
+ ...options ,
126
+ } ) ,
123
127
overrideConfig ,
124
128
) ;
125
129
}
You can’t perform that action at this time.
0 commit comments