I m trying to import Blur View in my app but I m getting this error:-
Module not found: Can't resolve './src/BlurView'
MY CODE
import React from "react";
import { ImageBackground, StyleSheet, Text, View, Button } from "react-native";
import { BlurView } from "@react-native-community/blur";
const App = () => (
<View style={styles.container}>
<ImageBackground source={require ('./assets/bg.jpg') } style={styles.image}>
<View style= {styles.main_container}>
<View style= {styles.button_container}>
<Button title= '1' color= '#ffffff00' />
</View>
</View>
</ImageBackground>
</View>
);
const styles = StyleSheet.create({
main_container: {
flex: 1,
height: '100%',
width: undefined,
backgroundColor: '#ffffff30',
},
button_container: {
borderTopLeftRadius: 8,
borderTopRightRadius: 8,
borderWidth: 1,
borderColor: 'rgb(255,255,255)',
backgroundColor: '#ffffff70',
height: '70%',
width: '100%',
justifyContent: "center",
position: 'absolute',
bottom: 0,
},
button: {
color: '#ffffff00',
},
container: {
flex: 1,
flexDirection: "column"
},
image: {
flex: 1,
resizeMode: "stretch",
justifyContent: "center",
height: '100%',
width: undefined,
},
text: {
color: "white",
fontSize: 42,
fontWeight: "bold",
textAlign: "center",
backgroundColor: "#000000a0"
}
});
export default App;
Im just getting This error by importing Blur View.
Please tell me whats the problem here.
Versions--
React-Native -- 0.63.2
BTW Im getting TypeError in linear gradient package too..