How to set AppIcon in react native iOS:
In this post we are going to learn “How to Set Splash Screen and AppIcon in react native“, you can find my last post about starting a new project in react native, you find it here .
Step1:
Choose the image of size 1024px and image type jpg
Step2:
Open https://appicon.co/ , on/off the radio button choose the platform and click on generate you find the all app icon.
Step 3:
You can find all your images within the Assets.xcassets folder.
Step 4:
Next open the Xcode find Images.xcassets and click on AppIcon then calculate the size and drag-drop the images here.
Now clean and run the project, you see the app icon.
Please follow these steps for setting the splash screen:
- First, we need to export the splash screen image from the scratch file or which you have used, because we need 3(1x, 2x, 3x)- different size images.
- Now we open the Xcode and go to the images.xcassets folder drag and drop these 3 images here.
- Now we are going to set up the splash screen for this select LaunchScreen.xib file.
- Now on top select the library icon next to show the standard editor, then here find the image view.
- Drag and drop this image in splash screen rectangle and fit it into the screen, then click on hide and show the inspector where you select the show the attributes inspector, and change the name of the image view with your splash screen name.
- Now click on the show the size inspector and select all 4 – the size of auto-resizing.
- In bottom click on the add new constraint icon then select all 4 – constraint.
And we completed the react native splash screen and appIcon tutorial “How to Set Splash Screen and AppIcon in react native“.
After this, your image is showing in the splash rectangle box of your app, if all steps going good, then close the Xcode open it again then clear the project and run you see your splash screen.
And you can find my post on medium as well click here please follow me on medium as well.
And if any other issue then please comment.
Happy Coding Guyz
Hi, I am a professional Ionic and React Native Pixel Perfect App Designer and Developer, with expertise in Client Communication, Bug Fixing, Third Party Lib, Version Control Tools, Requirement Understanding, and managing teams, I have 6+ years of experience in the same domain as well as in Codeigniter, JS, IoT, and more than 10 other languages. For the last 6+ years, not a single day went without design/development.
Please follow me on Medium: https://nehadwivedi1004.medium.com/