Update RN and Viro. iOS build working

This commit is contained in:
John Lyon-Smith
2018-05-09 11:23:11 -07:00
parent 93cfa3b4dc
commit ccd159bb47
13 changed files with 1886 additions and 2274 deletions

View File

@@ -1,40 +1,39 @@
'use strict';
"use strict"
const blacklist = require('metro-bundler/src/blacklist');
const path = require('path');
const blacklist = require("metro/src/blacklist")
const path = require("path")
module.exports = {
getProjectRoots() {
return this._getRoots();
return this._getRoots()
},
getAssetRoots() {
return this._getRoots();
return this._getRoots()
},
getAssetExts() {
return ["obj", "mtl"];
return ["obj", "mtl"]
},
getBlacklistRE() {
return blacklist();
return blacklist()
},
_getRoots() {
// match on either path separator
if (__dirname.match(/node_modules[\/\\]react-native[\/\\]packager$/)) {
// packager is running from node_modules of another project
return [path.resolve(__dirname, '../../..')];
return [path.resolve(__dirname, "../../..")]
} else if (__dirname.match(/Pods\/React\/packager$/)) {
// packager is running from node_modules of another project
return [path.resolve(__dirname, '../../..')];
return [path.resolve(__dirname, "../../..")]
} else {
return [path.resolve(__dirname, '.')];
return [path.resolve(__dirname, ".")]
}
},
getTransformModulePath() {
return require.resolve('metro-bundler/src/transformer');
return require.resolve("metro/src/transformer")
},
};
}