Deploy v0.35.0

Reviewed By: davidaurelio

Differential Revision: D4177391

fbshipit-source-id: c02cf98ed275b7032103b11eab6d0e189f8d8f24
This commit is contained in:
Gabe Levi 2016-11-14 20:39:21 -08:00 committed by Facebook Github Bot
parent b64f892210
commit 4fafef79cb
3 changed files with 10 additions and 5 deletions

View File

@ -110,7 +110,11 @@ class BundleBase {
setRamGroups(ramGroups: Array<string>) {} setRamGroups(ramGroups: Array<string>) {}
toJSON(): mixed { toJSON(): {
modules: Array<ModuleTransport>,
assets: Array<mixed>,
mainModuleId: number | void,
} {
return { return {
modules: this._modules, modules: this._modules,
assets: this._assets, assets: this._assets,

View File

@ -114,11 +114,11 @@ class Module {
); );
} }
getCode(transformOptions: mixed) { getCode(transformOptions: Object) {
return this.read(transformOptions).then(({code}) => code); return this.read(transformOptions).then(({code}) => code);
} }
getMap(transformOptions: mixed) { getMap(transformOptions: Object) {
return this.read(transformOptions).then(({map}) => map); return this.read(transformOptions).then(({map}) => map);
} }
@ -154,7 +154,7 @@ class Module {
return this._moduleCache.getPackageForModule(this); return this._moduleCache.getPackageForModule(this);
} }
getDependencies(transformOptions: mixed) { getDependencies(transformOptions: Object) {
return this.read(transformOptions).then(({dependencies}) => dependencies); return this.read(transformOptions).then(({dependencies}) => dependencies);
} }
@ -244,7 +244,7 @@ class Module {
* dependencies, etc. The overall process is to read the cache first, and if * dependencies, etc. The overall process is to read the cache first, and if
* it's a miss, we let the worker write to the cache and read it again. * it's a miss, we let the worker write to the cache and read it again.
*/ */
read(transformOptions: mixed): Promise<ReadResult> { read(transformOptions: Object): Promise<ReadResult> {
const key = stableObjectHash(transformOptions || {}); const key = stableObjectHash(transformOptions || {});
const promise = this._readPromises.get(key); const promise = this._readPromises.get(key);
if (promise != null) { if (promise != null) {

View File

@ -165,6 +165,7 @@ function getReplacements(pkg) {
// merge with "browser" as default, // merge with "browser" as default,
// "react-native" as override // "react-native" as override
// $FlowFixMe(>=0.35.0) browser and rn should be objects
return { ...browser, ...rn }; return { ...browser, ...rn };
} }