JSFiddle - React, Tailwind, and code Playground

HTML

<style>
    div {
        background-color: blue;
    }
</style>

<div id="my_div" style="height: 100px; width:100px;"></div>

CSS

div {
    background-color: red;
}

JavaScript

setTimeout(function () {
    var ele = document.getElementById('my_div');
    document.styleSheets[3].disabled = true;
    var bg_color = window.getComputedStyle(ele).backgroundColor;
    document.styleSheets[3].disabled = false;
    alert('Original background color is: '+bg_color);
}, 1000);