JSFiddle - React, Tailwind, and code Playground

HTML

<div id="x" style="height: 150px"></div>

JavaScript

alert($("#x").width());
alert($("#x").height());