<pclass="arguement"><strong>target</strong> An object that will receive the new properties if additional objects are passed in or that will extend the jQuery namespace if it is the sole argument.</p>
<pclass="arguement"><strong>object1</strong>An object containing additional properties to merge in.</p>
<pclass="arguement"><strong>objectN</strong>Additional objects containing properties to merge in.</p>
<pclass="arguement"><strong>deep</strong>If true, the merge becomes recursive (aka. deep copy).</p>
<pclass="arguement"><strong>target</strong>The object to extend. It will receive the new properties.</p>
<pclass="arguement"><strong>object1</strong>An object containing additional properties to merge in.</p>
<pclass="arguement"><strong>objectN</strong>Additional objects containing properties to merge in.</p>
</li>
</ul>
<divclass="longdesc">
<p>When we supply two or more objects to <code>$.extend()</code>, properties from all of the objects are added to the target object.</p>
<p>If only one argument is supplied to <code>$.extend()</code>, this means the target argument was omitted. In this case, the jQuery object itself is assumed to be the target. By doing this, we can add new functions to the jQuery namespace. This can be useful for plugin authors wishing to add new methods to JQuery.</p>
<p>Keep in mind that the target object (first argument) will be modified, and will also be returned from <code>$.extend()</code>. If, however, we want to preserve both of the original objects, we can do so by passing an empty object as the target:</p>
<p>The merge performed by <code>$.extend()</code> is not recursive by default; if a property of the first object is itself an object or array, it will be completely overwritten by a property with the same key in the second object. The values are not merged. This can be seen in the example below by examining the value of banana. However, by passing <code>true</code> for the first function argument, objects will be recursively merged.</p>
<p>Undefined properties are not copied. However, properties inherited from the object's prototype <em>will</em> be copied over.</p>
</div>
<h3>Examples:</h3>
<divid="entry-examples"class="entry-examples">
<divid="example-0">
<h4>Example: <spanclass="desc">Merge two objects, modifying the first.</span>