- Go backend (server/)
- Frontend (web/, server/static/)
- Database and deployment files
- Scripts and docs
Co-Authored-By: 狸花猫/Claude-Qwen3.6-Plus 🐾
31 lines
872 B
JavaScript
31 lines
872 B
JavaScript
import isFunction from './is-function';
|
|
import isEqual from './is-equal';
|
|
/**
|
|
* @param {*} value The value to compare.
|
|
* @param {*} other The other value to compare.
|
|
* @param {Function} [fn] The function to customize comparisons.
|
|
* @returns {boolean} Returns `true` if the values are equivalent, else `false`.
|
|
* @example
|
|
*
|
|
* function isGreeting(value) {
|
|
* return /^h(?:i|ello)$/.test(value);
|
|
* }
|
|
*
|
|
* function customizer(objValue, othValue) {
|
|
* if (isGreeting(objValue) && isGreeting(othValue)) {
|
|
* return true;
|
|
* }
|
|
* }
|
|
*
|
|
* var array = ['hello', 'goodbye'];
|
|
* var other = ['hi', 'goodbye'];
|
|
*
|
|
* isEqualWith(array, other, customizer); // => true
|
|
*/
|
|
export default (function (value, other, fn) {
|
|
if (!isFunction(fn)) {
|
|
return isEqual(value, other);
|
|
}
|
|
return !!fn(value, other);
|
|
});
|
|
//# sourceMappingURL=is-equal-with.js.map
|