JSFiddle - React, Tailwind, and code Playground

by tyage

HTML

<select id="foo">
    <option>1</option>
    <option>2</option>
    <option>3</option>
</select>

<select id="bar">
    <option>1</option>
    <option>2</option>
    <option>3</option>
</select>

JavaScript

document.getElementById('foo').addEventListener('change', function() {
});
document.getElementById('bar').addEventListener('change', function() {
    window.getComputedStyle(document.body, null).getPropertyValue('width');
});