Skip to content

Instantly share code, notes, and snippets.

@MarcosSarges
Last active June 15, 2019 18:24
Show Gist options
  • Save MarcosSarges/e14fafb7e78aa855c9f1cd59085e945a to your computer and use it in GitHub Desktop.
Save MarcosSarges/e14fafb7e78aa855c9f1cd59085e945a to your computer and use it in GitHub Desktop.
import React from "react";
import { ScrollView, Image, Text } from "react-native";
const data = Array(30)
.fill(0)
.map((el, i) => (
<Text
style={{
marginVertical: 10,
textAlign: "center",
fontSize: 20,
color: "#fff"
}}
key={i}
>
{i}
</Text>
));
const AnimacaoScrollView = () => {
return (
<View style={{flex:1}}>
<ScrollView style={{ flex: 1, backgroundColor: "pink" }}>
{data}
</ScrollView>
<Image
source={require("./download.jpg")}
resizeMode="cover"
style={{ height: 250, width: "100%" }}
/>
</View>
);
};
export default AnimacaoScrollView;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment