mirror of
https://gitcode.com/gh_mirrors/re/react-native-pushy.git
synced 2025-10-08 10:15:14 +08:00
bugfix: failed run with React Native 0.33
This commit is contained in:
@@ -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
|
||||||
|
Reference in New Issue
Block a user