From b2d5faa498488387714442ca45199c41e697420f Mon Sep 17 00:00:00 2001 From: Harjot Singh Date: Tue, 21 Dec 2021 19:00:12 +0000 Subject: [PATCH] refactor: remove app.json and use generic "App" component name --- android/app/src/main/java/com/shabados/app/MainActivity.java | 2 +- app.json | 4 ---- index.js | 3 +-- ios/Mobile/AppDelegate.m | 2 +- 4 files changed, 3 insertions(+), 8 deletions(-) delete mode 100644 app.json diff --git a/android/app/src/main/java/com/shabados/app/MainActivity.java b/android/app/src/main/java/com/shabados/app/MainActivity.java index be345592..a48d6cc5 100644 --- a/android/app/src/main/java/com/shabados/app/MainActivity.java +++ b/android/app/src/main/java/com/shabados/app/MainActivity.java @@ -10,6 +10,6 @@ public class MainActivity extends ReactActivity { */ @Override protected String getMainComponentName() { - return "Mobile"; + return "App"; } } diff --git a/app.json b/app.json deleted file mode 100644 index 6ca15ed5..00000000 --- a/app.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "Mobile", - "displayName": "Shabad OS" -} diff --git a/index.js b/index.js index 0fb71c14..57eab20c 100644 --- a/index.js +++ b/index.js @@ -3,9 +3,8 @@ import 'react-native-gesture-handler' import { AppRegistry } from 'react-native' import { enableScreens } from 'react-native-screens' -import { name as appName } from './app.json' import App from './src/App' enableScreens() -AppRegistry.registerComponent( appName, () => App ) +AppRegistry.registerComponent( 'App', () => App ) diff --git a/ios/Mobile/AppDelegate.m b/ios/Mobile/AppDelegate.m index e34c2324..bb1e8f44 100644 --- a/ios/Mobile/AppDelegate.m +++ b/ios/Mobile/AppDelegate.m @@ -33,7 +33,7 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:( RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:launchOptions]; RCTRootView *rootView = [[RCTRootView alloc] initWithBridge:bridge - moduleName:@"Mobile" + moduleName:@"App" initialProperties:nil]; if (@available(iOS 13.0, *)) {