I have an issue with android. The file in the Android assets directory is not found.
Error:
Error while updating property 'sourceName' of a view managed by: LottieAnimationView
null
Unable to find file loading.js
Animation file location:
app/src/main/assets/loading.json
Component:
class Loading extends Component {
componentDidMount() {
this.animation.play()
}
render() {
return (
<View style={StyleSheet.loading.page}>
<View style={StyleSheet.loading.animationWrapper}>
<Animation
ref={animation => { this.animation = animation }}
style={StyleSheet.loading.animation}
loop
source="loading.json"
/>
</View>
<Text style={StyleSheet.loading.text}>LOADING</Text>
</View>
)
}
}
Versions:
"lottie-react-native": "2.2.0"
"react-native": "0.47.2"