JSFiddle - React, Tailwind, and code Playground

HTML

<div id="test-element">
    This is a Test element, look at the olddisplay data property:<br />
</div>
Additionally the display css property is now explicitly set on the element

JavaScript

$(function() {
    $('#test-element').hide().show();
    $('#test-element').html($('#test-element').html() + "olddisplay: " + JSON.stringify($('#test-element').data()));
    console.log($('#test-element').data(), $('#test-element'));
})