UNPKG

@stdlib/utils

Version:

Standard utilities.

30 lines (22 loc) 544 B
{{alias}}( obj1, obj2[, ...obj] ) Returns the common own property names of two or more objects. Parameters ---------- obj1: any First object. obj2: any Second object. obj: ...any (optional) Additional objects. Returns ------- out: Array<string> Common keys of objects. Examples -------- > var obj1 = { 'a': 1, 'b': 2 }; > var obj2 = { 'a': 1, 'b': 2, 'c': 3, 'd': 4 }; > var keys = {{alias}}( obj1, obj2 ) [ 'a', 'b' ] See Also --------