0

Hello I just started to use React Native and I want to use an image as background but when press to an input text the image moves a little bit up and I want to be fixed.

const backgroundImage = './assets/background-blur.jpg'

const App = () => {
    return (
        <View>
            <ImageBackground source={require(backgroundImage)} style={style.background}>
                <ScrollView>
                    <SearchInput />
                </ScrollView>
            </ImageBackground>
        </View>
    )
}

const style = StyleSheet.create({
    background: {
        width: '100%',
        height: '100%'
    }
})

Any suggestion?

ravibagul91
  • 18,551
  • 5
  • 33
  • 54
Jonathan Gómez
  • 343
  • 4
  • 17

0 Answers0