react-native-carousel
react-native-carousel copied to clipboard
Bug: carousel does not responding to orientation changes
Hi, all i have some troubles with plugin. Video preview for details: http://take.ms/NqnKe
In summary then you change orientation carousel does not change width/height. We have this bug in a few projects.
react & react native version ? working for me ` import React from 'react' import { View, Text, Image, ScrollView, Component, Dimensions,StyleSheet } from 'react-native' import Icon from 'react-native-vector-icons/MaterialIcons';
let Carousel = require('react-native-carousel') const { width } = Dimensions.get('window')
const PromotionSlider = ({url, ...rest}) => {
return (
<Carousel
width={200}
delay={4000}
{...rest}
>
<View style={styles.container}>
<Text>Page 2</Text>
</View>
<View style={styles.container}>
<Text>Page 3</Text>
</View>
</Carousel>
)
}
export default PromotionSlider
const styles = StyleSheet.create({
container: {
height: 200,
flex: 1,
justifyContent: 'center',
alignItems: 'center',
backgroundColor: 'pink',
}
})`