0
私はアンドロイドに問題があります。 Androidのアセットディレクトリにあるファイルが見つかりません。ファイルを見つけることができません(Android)
Error :-
Error while updating property 'sourceName' of a view managed by: LottieAnimationView
null
Unable to find file loading.js
アニメーションファイルの場所: -
app/src/main/assets/loading.json
コンポーネント: -
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>
)
}
}
バージョン: -
"lottie-react-native": "2.2.0"
"react-native": "0.47.2"
明らかに、Android Studioでプロジェクトを閉じたり開いたりするだけで、正常に動作するようになりました。 –
これは試してもうまくいかない:( – Lee
あなたの問題がなぜ解決されたのか? – Lee