I'm using this animation in my react native Expo app:
https://www.lottiefiles.com/86-bouncy-dribbble-ball
The animation runs, I can see the shadow of the ball but I can't see the ball image.
The image is defined like this in the animation json file:
[{"id":"image_0","w":289,"h":287,"u":"images/","p":"img_0.png"}]
I put the image and the json file into the same folder. I guess Lottie can't find the image. I tried lots of different combinations for the "u" parameter but I couldn't manage to show the image.
Any help is appreciated.
https://github.com/airbnb/lottie-react-native/issues/145
I found the solution - just drag the images folder into your bundle resources in your Xcode project.
Related
I've created a custom image picker using expo-media-library, and now I want to create a circular image crop mask, like on instagram or whatspp when you change the profile picture.
I found this package, https://github.com/ivpusic/react-native-image-crop-picker but it has some bugs.
Is it possible to create a custom image crop using existing react-native packages without working on native side?
Here's the packages I think could be useful:
#react-native-community/image-editor
react-native-masked-view/masked-view
Thank you
In a React native application, We are trying to load Lottie animation as a splash screen.
In android, I'm able to achieve it by creating a native view for the android Lottie library. I want to play lottie animation in splash screen+ React native
I need the same in iOS, currently, we have an image splash screen, which we have implemented images.xcassets and LaunchScreen.storyboard (refer to screenshots)
Is there any possibility to use Lottie animations instead of these images here?
There is a workaround where I can add the Lottie animation in the app.js before starting with app content. In this case, first, the above-mentioned splash screen comes and the animation. If I remove this splash screen here, then a white screen and the animation will come.
How to use the Lottie animation instead of splash screen image on iOS?
At first, I have searched many articles about changing ios's LaunchScreen.storyboard with lottie animation. However, Xcode enforces that LaunchScreen.storyboard should be static screen. So, I inserted animation code after static launch screen loading. Maybe, launch screen is essential, because it is loading screen for initial loading resource in ios. If you remove the launch screen, then ios app shows black or white screen at first loading. Remove launch screen, Xcode 7
If you looking for animation launch screen using lottie in react native, i would suggest looking into this package.
https://www.npmjs.com/package/react-native-lottie-splash-screen
It implements animation splash screen using airbnb lottie files. Also, I apply this for multiple react native projects and it worked well. Have a nice day!
In iOS, the splash screen is a view without any associated logic.
What you could do to give the impression of the animation is to have it look like the first frame of your Lottie file.
Then, in the didFinishLaunchingWithOptions, you can start your Lottie animation.
In a RN application, the splash screen should be a quick flash and most of the startup time would be taken up by the RN setup. So, the animation should show up relatively smoothly even with this approch.
You can take a look at this repo to see how they've implemented it.
I'm trying to implement a modal in which I show the user a 360 degree image and he can move the image freely, the problem is the only library I found for this, https://github.com/lightbasenl/react-native-panorama-view, can not be used in an expo managed workflow. I also found this old post How to show 360 images in the react native, but the answer is very old and I can't seem to make it work.
I'm wondering how to change an expo app's configurations. Examples of what I mean by configurations:
Make the app only available for tablets, require location/wi-fi connection/bluetooth connection, specify multiple icon sizes, etc ...
I'm asking this because I generated an ipa, tried to build it with Application Loader but I got this error:
Missing required icon file. The bundle does not contain an app for
iPhone / iPod Touch of exactly '120x120' pixels, in .png format for
iOS versions >= 7.0
Does this have anything to do with exp.json ?
Thanks!
Set application icon in this pixel
Most likely your watchKit app icons are not of the correct size. You need follow the instructions in above image
Resizing the Icon to have square values (width = height) did the trick. The icon has to be a square.
See https://github.com/expo/expo/issues/278#issuecomment-309078847
I want to build an application that when the folder is drag and drop to my app, it will retain path and show custom image. so here is the screen shot of my app.
So as you can see in the screen shot, when i drag and drop folder on my app it will display the folder with the custom frame. So the problem is i want to change the folder icon shown in my app to other picture. I am still new to cocoa programming so i hope anyone can point what code to use to change the folder icon in my app. anyway i am using xcode 3.2 to build my app.
You need to point to a directory that contains images. if you point to a directory that only contains directories, this is what you get.