HEX
Server: nginx/1.18.0
System: Linux vcwordpress 5.15.0-174-generic #184-Ubuntu SMP Fri Mar 13 18:41:50 UTC 2026 x86_64
User: root (0)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/igsms.viitorcloud.co/igsmsportal/node_modules/es-toolkit/dist/array/isSubsetWith.d.mts
/**
 * Checks if the `subset` array is entirely contained within the `superset` array based on a custom equality function.
 *
 * This function takes two arrays and a custom comparison function. It returns a boolean indicating
 * whether all elements in the subset array are present in the superset array, as determined by the provided
 * custom equality function.
 *
 * @template T - The type of elements contained in the arrays.
 * @param {T[]} superset - The array that may contain all elements of the subset.
 * @param {T[]} subset - The array to check against the superset.
 * @param {(x: T, y: T) => boolean} areItemsEqual - A function to determine if two items are equal.
 * @returns {boolean} - Returns `true` if all elements of the subset are present in the superset
 * according to the custom equality function, otherwise returns `false`.
 *
 * @example
 * ```typescript
 * const superset = [{ id: 1 }, { id: 2 }, { id: 3 }];
 * const subset = [{ id: 2 }, { id: 1 }];
 * const areItemsEqual = (a, b) => a.id === b.id;
 * isSubsetWith(superset, subset, areItemsEqual); // true
 * ```
 *
 * @example
 * ```typescript
 * const superset = [{ id: 1 }, { id: 2 }, { id: 3 }];
 * const subset = [{ id: 4 }];
 * const areItemsEqual = (a, b) => a.id === b.id;
 * isSubsetWith(superset, subset, areItemsEqual); // false
 * ```
 */
declare function isSubsetWith<T>(superset: readonly T[], subset: readonly T[], areItemsEqual: (x: T, y: T) => boolean): boolean;

export { isSubsetWith };