diff --git a/packages/metro/src/Config.js b/packages/metro/src/Config.js index 21cd3405..0107c802 100644 --- a/packages/metro/src/Config.js +++ b/packages/metro/src/Config.js @@ -166,7 +166,7 @@ const DEFAULT = ({ dynamicDepsInPackages: 'throwAtRuntime', getAssetExts: () => [], getBlacklistRE: () => blacklist(), - getEnableBabelRCLookup: () => false, + getEnableBabelRCLookup: () => true, getPlatforms: () => [], getPolyfillModuleNames: () => [], // We assume the default project path is two levels up from diff --git a/packages/metro/src/index.js b/packages/metro/src/index.js index 604d079d..17c935ec 100644 --- a/packages/metro/src/index.js +++ b/packages/metro/src/index.js @@ -125,6 +125,7 @@ async function runMetro({ blacklistRE: normalizedConfig.getBlacklistRE(), createModuleIdFactory: normalizedConfig.createModuleIdFactory, dynamicDepsInPackages: normalizedConfig.dynamicDepsInPackages, + enableBabelRCLookup: normalizedConfig.getEnableBabelRCLookup(), extraNodeModules: normalizedConfig.extraNodeModules, getPolyfills: normalizedConfig.getPolyfills, getModulesRunBeforeMainModule: diff --git a/packages/metro/src/shared/types.flow.js b/packages/metro/src/shared/types.flow.js index 0d2cb150..95465616 100644 --- a/packages/metro/src/shared/types.flow.js +++ b/packages/metro/src/shared/types.flow.js @@ -78,7 +78,7 @@ export type Options = {| cacheVersion?: string, createModuleIdFactory?: () => (path: string) => number, +dynamicDepsInPackages: DynamicRequiresBehavior, - enableBabelRCLookup?: boolean, + enableBabelRCLookup: boolean, extraNodeModules?: {}, getPolyfills: ({platform: ?string}) => $ReadOnlyArray, getTransformOptions?: GetTransformOptions,