Use .babelrc from different path
问题 Is there a way to provide the path to the .babelrc file to babel-cli? Something like: babel src --out-dir lib --config random-folder/sub-folder/.babelrc 回答1: Considering the version you are using you may try extends or babelrc http://henryzoo.com/babel.github.io/docs/usage/options/ 回答2: You can put the .babelrc file in a shared parent directory of the other 5 modules as the lookup behavior of babel regarding the .babelrc is: Babel will look for a .babelrc in the current directory of the file