JSFiddle - React, Tailwind, and code Playground

HTML

<div id="divA">I'm a div. Get my width!</div>




<!-- Just for output -->
<p id=result></p>

CSS

#divA{
  width: 500px;
}

JavaScript

$(document).ready(function(){

  $("#result").html(
  "<br />JQUERY says: " + $("#divA").width() + 
  "<br />JAVASCRIPT says: " + document.getElementById("divA").style.width
  );

});