mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-01 15:57:48 +00:00
Update _.union documentation (#3758)
Clarifying example as per https://github.com/lodash/lodash/issues/3757
This commit is contained in:
4
union.js
4
union.js
@@ -14,8 +14,8 @@ import isArrayLikeObject from './isArrayLikeObject.js'
|
||||
* @see difference, unionBy, unionWith, without, xor, xorBy
|
||||
* @example
|
||||
*
|
||||
* union([2], [1, 2])
|
||||
* // => [2, 1]
|
||||
* union([2, 3], [1, 2])
|
||||
* // => [2, 3, 1]
|
||||
*/
|
||||
function union(...arrays) {
|
||||
return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true))
|
||||
|
||||
Reference in New Issue
Block a user