• Performs a SameValueZero comparison between two values to determine if they are equivalent.

    Parameters

    • value: any

      The value to compare.

    • other: any

      The other value to compare.

    Returns boolean

    Returns true if the values are equivalent, else false.

    var object = { 'user': 'fred' };
    var other = { 'user': 'fred' };

    _.eq(object, object);
    // => true

    _.eq(object, other);
    // => false

    _.eq('a', 'a');
    // => true

    _.eq('a', Object('a'));
    // => false

    _.eq(NaN, NaN);
    // => true