From 3ed489a35aeadeb0fd6880e46c3262ff99dc160e Mon Sep 17 00:00:00 2001 From: David Aurelio Date: Wed, 3 May 2017 13:02:05 -0700 Subject: [PATCH] Make bundle building function async Reviewed By: jeanlauliac Differential Revision: D4993758 fbshipit-source-id: b466e0d8d494914357f38eac1a0ef3c2ec7d4edd --- packages/metro-bundler/src/ModuleGraph/ModuleGraph.js | 2 +- packages/metro-bundler/src/ModuleGraph/types.flow.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/metro-bundler/src/ModuleGraph/ModuleGraph.js b/packages/metro-bundler/src/ModuleGraph/ModuleGraph.js index 757fe16f..9d67a024 100644 --- a/packages/metro-bundler/src/ModuleGraph/ModuleGraph.js +++ b/packages/metro-bundler/src/ModuleGraph/ModuleGraph.js @@ -27,7 +27,7 @@ import type { type BuildFn = ( entryPoints: Iterable, options: BuildOptions, - callback: Callback<{modules: Iterable, entryModules: Iterable}>, + callback: Callback, ) => void; type BuildOptions = {| diff --git a/packages/metro-bundler/src/ModuleGraph/types.flow.js b/packages/metro-bundler/src/ModuleGraph/types.flow.js index aedf1e08..dd105630 100644 --- a/packages/metro-bundler/src/ModuleGraph/types.flow.js +++ b/packages/metro-bundler/src/ModuleGraph/types.flow.js @@ -46,8 +46,8 @@ type GraphOptions = {| |}; export type GraphResult = {| - entryModules: Array, - modules: Array, + entryModules: Iterable, + modules: Iterable, |}; export type IdForPathFn = {path: string} => number;