JSFiddle - React, Tailwind, and code Playground
by arbaazshaikh919
HTML
<html>
<head>
<title>This centering test</title>
</head>
<boby>
<div class="container">
<div class="centerDivision">
<p>
this is centered division
</p>
</div>
</div>
</boby>
</html>
CSS
.container{
width: 100%;
}
.centerDivision{
/* position:absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%); */
display: flex;
justify-content: center;
align-items: center;
/* flex-direction: column; */
height: 100vh;
}