Do you want to request a feature or report a bug?
bug
What is the current behavior?
When running npx react-native bundle, metro will search for a metro.config.js file at the root of the project and not consider the current working directory (in fact I think the cwd is calculated to be the root of the project by a module called commander)
If the current behavior is a bug, please provide the steps to reproduce and a minimal repository on GitHub that we can yarn install and yarn test.
In the @react-native-community/clipboard repo, if you try to run react-native-bundle for the example app (i.e. in the example directory), the metro.config.js file in the example directory is not loaded and instead an empty one is.
What is the expected behavior?
The actual current working directory is inspected and fall back to the root of the project.
Or please document that the metro.config.js file must be at the root of the project and not in a subfolder.
Please provide your exact Metro configuration and mention your Metro, node, yarn/npm version and operating system.
metro 0.58
node 12.9.1
npm 6.10.2
yarn 1.22.4
Windows 10 19041
Do you want to request a feature or report a bug?
bug
What is the current behavior?
When running
npx react-native bundle, metro will search for a metro.config.js file at the root of the project and not consider the current working directory (in fact I think the cwd is calculated to be the root of the project by a module calledcommander)If the current behavior is a bug, please provide the steps to reproduce and a minimal repository on GitHub that we can
yarn installandyarn test.In the @react-native-community/clipboard repo, if you try to run react-native-bundle for the
exampleapp (i.e. in theexampledirectory), the metro.config.js file in theexampledirectory is not loaded and instead an empty one is.What is the expected behavior?
The actual current working directory is inspected and fall back to the root of the project.
Or please document that the metro.config.js file must be at the root of the project and not in a subfolder.
Please provide your exact Metro configuration and mention your Metro, node, yarn/npm version and operating system.
metro 0.58
node 12.9.1
npm 6.10.2
yarn 1.22.4
Windows 10 19041