Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import { StatusBar } from 'expo-status-bar';
- import { TouchableOpacity, Image, StyleSheet, Text, View, ScrollView, Dimensions, Button } from 'react-native';
- const { width } = Dimensions.get("window");
- const height = width;
- const images = [
- require('./assets/landing/girl1.png'),
- require('./assets/landing/girl2.png'),
- require('./assets/landing/girl3.png'),
- ]
- export default function App() {
- return (
- <View style={{ marginTop: 50, width, height }}>
- <StatusBar style="auto" />
- <ScrollView pageEnabled horizontal style={{ width, height }} showsHorizontalScrollIndicator={false}>
- <Image source={images[2]} style={{ resizeMode: 'cover', marginLeft: -200 }} />
- {
- images.map((item, index) => (
- <Image key={index} source={item} style={styles.images} />
- ))
- }
- <Image source={images[0]} style={{ resizeMode: 'cover', marginLeft: 50 }} />
- </ScrollView>
- <TouchableOpacity style={styles.button} >
- <Text style={{ color: 'white', fontWeight: '500', fontSize: 16 }}> Create an account </Text>
- </TouchableOpacity>
- </View>
- );
- }
- const styles = StyleSheet.create({
- images: {
- resizeMode: 'cover',
- marginLeft: 50
- },
- button: {
- width: 295,
- height: 55,
- backgroundColor: '#E94057',
- color: 'white',
- borderRadius: 15,
- alignSelf: 'center',
- alignItems: 'center',
- justifyContent: 'center',
- position: 'relative',
- top: 220,
- }
- });
Advertisement
Add Comment
Please, Sign In to add comment