JSFiddle - React, Tailwind, and code Playground

HTML

<div class="box"></div>

CSS

body {
    background: #888;
}

.box {
    width: 100px;
    height: 100px;
    background: #ccc;
    position: absolute;
    left: 50%;
    top: 50%;
    margin: -50px 0 0 -50px;
}