-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
195 changed files
with
3,940 additions
and
4,786 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
.buildkite/jobs/pipeline.android_rn_75.yml → .../jobs/pipeline.android_rn_76_old_arch.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
...kite/jobs/pipeline.ios_demo_app_rn_76.yml → .../pipeline.ios_demo_app_rn_76_new_arch.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
- label: ":ios::react: RN .76 + iOS: Demo app" | ||
- label: ":new::ios::react: RN .76 + iOS: Demo app" | ||
command: | ||
- "nvm install" | ||
- "./scripts/demo-projects.ios.sh" | ||
env: | ||
REACT_NATIVE_VERSION: 0.76.3 | ||
RCT_NEW_ARCH_ENABLED: 1 | ||
artifact_paths: | ||
- "/Users/builder/uibuilder/work/coverage/**/*.lcov" | ||
- "/Users/builder/uibuilder/work/artifacts*.tar.gz" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 3 additions & 2 deletions
5
.buildkite/jobs/pipeline.ios_rn_75.yml → ...kite/jobs/pipeline.ios_rn_76_new_arch.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
detox/android/detox/src/full/java/com/wix/detox/reactnative/ReactApplicationExt.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package com.wix.detox.reactnative | ||
|
||
import android.annotation.SuppressLint | ||
import com.facebook.react.ReactApplication | ||
import com.facebook.react.ReactInstanceManager | ||
import com.facebook.react.bridge.ReactContext | ||
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint | ||
|
||
|
||
fun ReactApplication.getInstanceManagerSafe(): ReactInstanceManager { | ||
return reactNativeHost.reactInstanceManager | ||
?: throw RuntimeException("ReactInstanceManager is null!") | ||
} | ||
|
||
@SuppressLint("VisibleForTests") | ||
fun ReactApplication.getCurrentReactContext(): ReactContext? { | ||
return if (isFabricEnabled()) { | ||
reactHost?.currentReactContext | ||
} else { | ||
getInstanceManagerSafe().currentReactContext | ||
} | ||
} | ||
|
||
fun ReactApplication.getCurrentReactContextSafe(): ReactContext { | ||
return getCurrentReactContext() | ||
?: throw RuntimeException("ReactContext is null!") | ||
} | ||
|
||
/** | ||
* A method to check if Fabric is enabled in the React Native application. | ||
*/ | ||
fun isFabricEnabled(): Boolean { | ||
return DefaultNewArchitectureEntryPoint.fabricEnabled | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.