maxs15 / react-native-spinkit

A collection of animated loading indicators for React Native
MIT License
2.36k stars 300 forks source link

Component doesnt animate on Android #30

Open melihmucuk opened 8 years ago

melihmucuk commented 8 years ago

React-Native v0.30 react-native-spinkit v1.2.0 and v1.3.0

With rnpm link, it shows red square. After that, I tried manual installation, then spinkit doesnt animate.

DeveloperAlly commented 7 years ago

Hi there @melihmucuk

Try adding the following code to the index.android.js right before AppRegistry...

code to add:

UIManager.setLayoutAnimationEnabledExperimental(true);

Example usage:

import { AppRegistry, UIManager } from 'react-native'; import App from './src/app';

UIManager.setLayoutAnimationEnabledExperimental(true); AppRegistry.registerComponent('tech_stack', () => App);

Hope this helps!

DeveloperAlly commented 7 years ago

in case of red square problem if this doesnt help try.... Followed manual setup guide: https://github.com/maxs15/react-native-spinkit/wiki/Manual-linking---Android

Found that the linking hadn't worked properly in Android java files and fixed it accordingly

This solved the issue!1 💃 YAY

Great react-native component. Thanks =D