jQuery FadeTo behavior

The fadeTo() method with a value of 0 changes the opacity but doesn't hide (display:none) an element.

by fparent

HTML

<div>
    You can still click the hidden button below...<br />
    <button id="xxx" value="button" />
<div>

CSS

div { border:solid 1px #000; }

button { 
    width:100px; height:100px; 
    background-color:cyan;
    cursor:pointer;
}

JavaScript

$('button').fadeTo(0, 0);