What does the or operator do in this bit of JavaScript?
<p>So I was browsing the JQuery source for better programming tips, and I found a bit of code where I'm not sure what's going on.</p>

<pre><code>type = type || callback;
</code></pre>

<p>Can anyone explain what the OR || is doing in the variable assignment?</p>

<p>I did a few experiments, setting and un-setting values and what-not, but I'm none the wiser.</p>
