|
@@ -23,20 +23,23 @@ class MainApplication : Application(), ReactApplication {
|
|
|
add(NavigationPackage())
|
|
|
}
|
|
|
|
|
|
+ override fun getJSMainModuleName(): String =
|
|
|
+ if (getUseDeveloperSupport()) "index" else "commom"
|
|
|
+
|
|
|
+ override fun getBundleAssetName(): String? =
|
|
|
+ if (getUseDeveloperSupport()) "index.android.bundle" else null
|
|
|
+
|
|
|
//
|
|
|
-// override fun getJSMainModuleName(): String =
|
|
|
-// if (getUseDeveloperSupport()) "index" else "commom"
|
|
|
-//
|
|
|
-// override fun getBundleAssetName(): String? =
|
|
|
-// if (getUseDeveloperSupport()) "index.android.bundle" else null
|
|
|
-//
|
|
|
// override fun getJSBundleFile(): String? = if (getUseDeveloperSupport()) {
|
|
|
// super.getJSBundleFile()
|
|
|
// } else {
|
|
|
// FileHelper.getFilePath("common.android.bundle", this@MainApplication, "bundles")
|
|
|
// }
|
|
|
- override fun getJSBundleFile(): String =
|
|
|
+ override fun getJSBundleFile(): String? = if (getUseDeveloperSupport()) {
|
|
|
+ null
|
|
|
+ } else {
|
|
|
FileHelper.getFilePath("common.android.bundle", this@MainApplication, "bundles")
|
|
|
+ }
|
|
|
|
|
|
override fun getUseDeveloperSupport(): Boolean = BuildConfig.DEBUG
|
|
|
|
|
@@ -47,7 +50,7 @@ class MainApplication : Application(), ReactApplication {
|
|
|
override val reactHost: ReactHost
|
|
|
get() = getDefaultReactHost(applicationContext, reactNativeHost)
|
|
|
|
|
|
- companion object{
|
|
|
+ companion object {
|
|
|
var isNew = true
|
|
|
}
|
|
|
|