Categories

jQuery.mixin()

Categories: Utilities

jQuery.mixin( target, [ target1 ], [ targetN ] )Returns: Object

Plugin: jQuery.mixin

Description: Merge the contents of two or more objects together into the first object.

  • jQuery.mixin( target, [ target1 ], [ targetN ] )

    version added: 1.0

    target   Object ...

    target1   Object ...

    targetN   Object ...

The jQuery.mixin() methods works like the jQuery.extend() method, but jQuery.mixin() extends the target only with own properties of target1 and targetN.

  • Extend the ep object with some methods.

    Code:
    jQuery.mixin({
        bar: function(){
        },
        foo: function(){
        }
    });
    // will add the bar and foo method to the ep namespace
    jQuery.bar();
    
    jQuery.foo();