-1

I have a react native app created. Image assets and react-native-vector-icons are loading correctly. But network images are not loading. Images are being fetched from aws as signed url. Those links are working correctly on android.

Tried this fix - https://github.com/facebook/react-native/issues/29279#issuecomment-658244428

I don't think the patch fix is required https://github.com/facebook/react-native/issues/29279#issuecomment-657284028 as my react-native version is 0.70.1

App Information

"react-native": "0.70.1"
Xcode Version 13.2.1 (13C100)
  • Please add new image url so i can check it. – Engr.Aftab Ufaq Feb 08 '23 at 04:51
  • @Engr.AftabUfaq example url http://s3-us-west-2.amazonaws.com/reacted/profile_image/kane-brown.jpg?X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAY4GBF6Z3MMICD4H7%2F20230208%2Fus-west-2%2Fs3%2Faws4_request&X-Amz-Date=20230208T050054Z&X-Amz-SignedHeaders=host&X-Amz-Expires=300&X-Amz-Signature=de4bd14c4d96e581a4fe23950293854f14a0f90f3ec9a158e167c5212ee8d8a8 – Abhimanyu Patil Feb 08 '23 at 05:01

1 Answers1

1

ok. the URL you shared is http and iOS does not all http request. to allow http request in iOS please add this to info.plist file

<key>NSAppTransportSecurity</key>
<dict>
    <key>NSAllowsArbitraryLoads</key>
    <true/>
</dict>

for more details please see this question and answer

Engr.Aftab Ufaq
  • 3,356
  • 3
  • 21
  • 47