这个主要是复制项目后项目名称修改不一致导致的:
根目录.js中
AppRegistry.registerComponent('项目名',() => ...);
app.json
与./ios/项目名/appDelegate.m中的
RCTRootView*rootView = [[RCTRootViewalloc]initWithBundleURL:jsCodeLocation
moduleName:@"项目名" launchOptions:launchOptions];
或是./android/app/src/main/java/com/项目名/MainActivity.java中的
mReactRootView.startReactApplication(mReactInstanceManager, "项目名", null);