Can I change the way a $.fn. function is declared?
<p>I have the following code:</p>

<pre><code>$.fn.buildTableOfContent = function () {
    var h2 = this.find('h2');
    if (h2.length &gt; 0) {
</code></pre>

<p>I would like to change it around so it's not declared as a variable:</p>

<pre><code>function $.fn.buildTableOfContent () {
    var h2 = this.find('h2');
    if (h2.length &gt; 0) {
</code></pre>

<p>Is it possible to do this like the above? I have done this for regular functions but not sure about ones that start with $.fn.  Am I correct in saying that $.fn. adds the function the the jQuery namespace?</p>
