Skip to content

Instantly share code, notes, and snippets.

@remirobert
Created December 22, 2015 02:36
Show Gist options
  • Save remirobert/27beba94b8d7e100f077 to your computer and use it in GitHub Desktop.
Save remirobert/27beba94b8d7e100f077 to your computer and use it in GitHub Desktop.
/**
* Sample React Native App
* https://github.com/facebook/react-native
*/
'use strict';
var React = require('react-native');
var {
AppRegistry,
StyleSheet,
Text,
View,
Image
} = React;
var gifTest = React.createClass({
render: function() {
return (
<View style={styles.container}>
<Image
style={styles.animatedImage}
source={{uri:"http://i.giphy.com/13YkBrhLJdziXm.gif"}}/>
<Text style={styles.welcomeText}>
{"Hello world !"}
</Text>
</View>
);
}
});
var styles = StyleSheet.create({
container: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
backgroundColor: 'black'
},
animatedImage: {
width:200,
height:200
},
welcomeText: {
paddingTop: 40,
color:'white',
fontSize: 30
}
});
AppRegistry.registerComponent('gifTest', () => gifTest);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment