source: node_modules/es-toolkit/dist/array/xorBy.mjs

Last change on this file was a762898, checked in by istevanoska <ilinastevanoska@…>, 5 months ago

Added visualizations

  • Property mode set to 100644
File size: 368 bytes
Line 
1import { differenceBy } from './differenceBy.mjs';
2import { intersectionBy } from './intersectionBy.mjs';
3import { unionBy } from './unionBy.mjs';
4
5function xorBy(arr1, arr2, mapper) {
6 const union = unionBy(arr1, arr2, mapper);
7 const intersection = intersectionBy(arr1, arr2, mapper);
8 return differenceBy(union, intersection, mapper);
9}
10
11export { xorBy };
Note: See TracBrowser for help on using the repository browser.