JSFiddle - React, Tailwind, and code Playground

by JamesD

HTML

<link rel="stylesheet" href="http://twitter.github.io/bootstrap/assets/css/bootstrap.css">
<input type="submit" class="btn" value="My Input Submit"/>
<input type="button" class="btn" value="My Input Button"/>
<button class="btn">My Button</button>

JavaScript

$(function() {
    jQuery.fn.extend({
        disable: function(state) {
            return this.each(function() {
                this.disabled = state;
            });
        }
    });
    
    $('input[type="submit"], input[type="button"], button').disable(true);
});