JSFiddle - React, Tailwind, and code Playground

by Shubham Agrawal

HTML

<button id="load">
  Load
</button>
<button id="file">
  FILE
</button>
<button id="file1">
  FILE 1
</button>
<button id="file2">
  FILE 2
</button>
<button id="file3">
  FILE 3
</button>

JavaScript

$('#load').click(function() {
  $('button').not(this).prop('disabled', function(_, val) {
    return !val;
  });
});
// TO check whether the other buttons are disabled or not
$('button').not("#load").click(function() {
  alert("CLICKED");
});