1
0
mirror of https://gitcode.com/gh_mirrors/re/react-native-pushy.git synced 2025-10-08 18:15:14 +08:00
Code Issues Packages Projects Releases Wiki Activity GitHub Gitee

bugfix: failed run with React Native 0.33

This commit is contained in:
tdzl2003
2016-09-22 06:45:29 +08:00
parent 7bf0fb12de
commit d8cc6cc4c0

View File

@@ -365,10 +365,16 @@ export const commands = {
const Config = require(path.resolve('node_modules/react-native/local-cli/util/Config')); const Config = require(path.resolve('node_modules/react-native/local-cli/util/Config'));
const bundle = require(path.resolve('node_modules/react-native/local-cli/bundle/bundle')); const bundle = require(path.resolve('node_modules/react-native/local-cli/bundle/bundle'));
const defaultConfig = let defaultConfig;
Config.get(path.resolve('node_modules/react-native/local-cli'),
require(path.resolve('node_modules/react-native/local-cli/default.config')) if (major >= 0 && minor >= 33) {
); defaultConfig= Config.get(
path.resolve('node_modules/react-native/local-cli'),
require(path.resolve('node_modules/react-native/local-cli/default.config')),
path.resolve('node_modules/react-native/packager/rn-cli.config.js'));
} else {
defaultConfig= Config.get(path.resolve('node_modules/react-native/local-cli'), require(path.resolve('node_modules/react-native/local-cli/default.config')));
}
if (bundle.func) { if (bundle.func) {
// React native after 0.31.0 // React native after 0.31.0