• Returns whether all the elements in the given objects are null or undefined

    Parameters

    • Optionalobjects: any[]

      the objects to check

    Returns boolean

    whether all the elements in the given objects are null or undefined

    allNil([null, undefined]);    // true
    allNil([null, {}]); // false
    allNil([null, 'foobar']); // false