Answers for "react center a div"

1

react place div at center of page

<div style={{display: 'flex',  justifyContent:'center', alignItems:'center', height: '100vh'}}>
    <h1> I am centered </h1>
</div>
Posted by: Guest on October-14-2020
0

center child components in react

var styles = StyleSheet.create({
    content:{
        flex:1,
        flexDirection:'row',
        alignItems:'center',
        justifyContent:'center'
    },
   …
});
Posted by: Guest on October-02-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language