Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Image defaultSource on Android Builds behaves differently than iOS #41124

Open
grgmo opened this issue Oct 20, 2023 · 0 comments
Open

Image defaultSource on Android Builds behaves differently than iOS #41124

grgmo opened this issue Oct 20, 2023 · 0 comments
Labels
Component: Image Issue: Author Provided Repro This issue can be reproduced in Snack or an attached project. Needs: Triage 🔍 Platform: Android Android applications. Platform: iOS iOS applications.

Comments

@grgmo
Copy link
Contributor

grgmo commented Oct 20, 2023

Description

Similar to closed issues that were missing repro links -

#31287
#38875

Based on the documentation https://reactnative.dev/docs/image#defaultsource Image defaultSource on Android gets ignored on debug but should work on release mode.

No issues on iOS new and old architecture
Android not working as expected new and old architecture

React Native Version

0.72.6

Output of npx react-native info

System:
OS: macOS 13.3.1
CPU: (10) arm64 Apple M1 Pro
Memory: 165.50 MB / 16.00 GB
Shell:
version: "5.9"
path: /bin/zsh
Binaries:
Node:
version: 16.14.2
path: ~/.nvm/versions/node/v16.14.2/bin/node
Yarn:
version: 1.22.19
path: ~/.nvm/versions/node/v16.14.2/bin/yarn
npm:
version: 8.5.0
path: ~/.nvm/versions/node/v16.14.2/bin/npm
Watchman:
version: 2023.02.06.00
path: /opt/homebrew/bin/watchman
Managers:
CocoaPods:
version: 1.12.1
path: /Users/gurung/.asdf/shims/pod
SDKs:
iOS SDK:
Platforms:
- DriverKit 22.4
- iOS 16.4
- macOS 13.3
- tvOS 16.4
- watchOS 9.4
Android SDK:
API Levels:
- "30"
- "31"
- "32"
- "33"
Build Tools:
- 30.0.3
- 31.0.0
- 32.0.0
- 33.0.0
System Images:
- android-30 | Google APIs ARM 64 v8a
- android-31 | Google APIs ARM 64 v8a
- android-31 | Google Play ARM 64 v8a
- android-32 | Google APIs ARM 64 v8a
- android-33 | Google APIs ARM 64 v8a
Android NDK: Not Found
IDEs:
Android Studio: 2021.1 AI-211.7628.21.2111.8309675
Xcode:
version: 14.3/14E222b
path: /usr/bin/xcodebuild
Languages:
Java:
version: 11.0.17
path: /usr/bin/javac
Ruby:
version: 3.0.3
path: /Users/gurung/.asdf/shims/ruby
npmPackages:
"@react-native-community/cli": Not Found
react:
installed: 18.2.0
wanted: 18.2.0
react-native:
installed: 0.72.6
wanted: 0.72.6
react-native-macos: Not Found
npmGlobalPackages:
"react-native": Not Found
Android:
hermesEnabled: true
newArchEnabled: false
iOS:
hermesEnabled: true
newArchEnabled: false

Steps to reproduce

Add Image with defaultSource that points to local image path and source with remote image.

run yarn android --mode release

Expected

Screen.Recording.2023-10-20.at.14.58.23.mov

Actual

It seems to render defaultSource briefly and when it's actually trying to load the remote image it disappears, but reappears briefly before rendering the remote image.

Screen.Recording.2023-10-20.at.15.01.26.mov

Snack, screenshot, or link to a repository

https://github.com/grgmo/react-native-android-image-defaultSource-repro

@github-actions github-actions bot added Component: Image Platform: Android Android applications. Platform: iOS iOS applications. labels Oct 20, 2023
@cortinico cortinico added the Issue: Author Provided Repro This issue can be reproduced in Snack or an attached project. label Oct 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Image Issue: Author Provided Repro This issue can be reproduced in Snack or an attached project. Needs: Triage 🔍 Platform: Android Android applications. Platform: iOS iOS applications.
Projects
None yet
Development

No branches or pull requests

2 participants