obj.js
Methods
- 
    
<static> assign(target)
 - 
    
    
Object.assign-style object shallow merge/extend.
Parameters:
Name Type Description targetObject target
...sourcesObject sources
Returns:
assign object
- Type
 - Object
 
 - 
    
<static> each(object, fn)
 - 
    
    
Array-like iteration for objects.
Parameters:
Name Type Description objectObject The object to iterate over
fnEachCallback The callback function which is called for each key in the object.
 - 
    
<static> isEmpty(value)
 - 
    
    
Check is Object is isEmpty
Parameters:
Name Type Description valueObject value
Returns:
isEmpty
- Type
 - boolean
 
 - 
    
<static> isObject(value)
 - 
    
    
Returns whether a value is an object of any kind - including DOM nodes,
arrays, regular expressions, etc. Not functions, though.This avoids the gotcha where using
typeofon anullvalue
results in'object'.Parameters:
Name Type Description valueObject value
Returns:
isObject
- Type
 - boolean
 
 - 
    
<static> isPlain(value)
 - 
    
    
Returns whether an object appears to be a "plain" object - that is, a
direct instance ofObject.Parameters:
Name Type Description valueObject value
Returns:
isPlain
- Type
 - boolean
 
 - 
    
<static> reduce(object, fn [, initial])
 - 
    
    
Array-like reduce for objects.
Parameters:
Name Type Argument Default Description objectObject The Object that you want to reduce.
fnfunction A callback function which is called for each key in the object. It
receives the accumulated value and the per-iteration value and key
as arguments.initialMixed <optional> 
0 Starting value
Returns:
The final accumulated value.
- Type
 - Mixed
 
 - 
    
<static> renameKeys(obj, newKeys)
 - 
    
    
Rename properties in a object
Parameters:
Name Type Description objObject obj
newKeysObject newKeys
Returns:
renameKeys
- Type
 - Object
 
 
Type Definitions
- 
    
obj:EachCallback(value, key)
 - 
    
    
    
    
    
        
Parameters:
Name Type Description valueMixed The current key for the object that is being iterated over.
keystring The current key-value for object that is being iterated over
 - 
    
obj:ReduceCallback(accum, value, key)
 - 
    
    
    
    
    
        
Parameters:
Name Type Description accumMixed The value that is accumulating over the reduce loop.
valueMixed The current key for the object that is being iterated over.
keystring The current key-value for object that is being iterated over
Returns:
The new accumulated value.
- Type
 - Mixed
 
 
EMP Html5 Player 2