|
Last change
on this file since ba17441 was a762898, checked in by istevanoska <ilinastevanoska@…>, 5 months ago |
|
Added visualizations
|
-
Property mode
set to
100644
|
|
File size:
892 bytes
|
| Line | |
|---|
| 1 | 'use strict';
|
|---|
| 2 |
|
|---|
| 3 | Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|---|
| 4 |
|
|---|
| 5 | const after = require('../../function/after.js');
|
|---|
| 6 | const isEqualWith$1 = require('../../predicate/isEqualWith.js');
|
|---|
| 7 |
|
|---|
| 8 | function isEqualWith(a, b, areValuesEqual) {
|
|---|
| 9 | if (typeof areValuesEqual !== 'function') {
|
|---|
| 10 | areValuesEqual = () => undefined;
|
|---|
| 11 | }
|
|---|
| 12 | return isEqualWith$1.isEqualWith(a, b, (...args) => {
|
|---|
| 13 | const result = areValuesEqual(...args);
|
|---|
| 14 | if (result !== undefined) {
|
|---|
| 15 | return Boolean(result);
|
|---|
| 16 | }
|
|---|
| 17 | if (a instanceof Map && b instanceof Map) {
|
|---|
| 18 | return isEqualWith(Array.from(a), Array.from(b), after.after(2, areValuesEqual));
|
|---|
| 19 | }
|
|---|
| 20 | if (a instanceof Set && b instanceof Set) {
|
|---|
| 21 | return isEqualWith(Array.from(a), Array.from(b), after.after(2, areValuesEqual));
|
|---|
| 22 | }
|
|---|
| 23 | });
|
|---|
| 24 | }
|
|---|
| 25 |
|
|---|
| 26 | exports.isEqualWith = isEqualWith;
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.