]> git.proxmox.com Git - mirror_xterm.js.git/blame - src/utils/Generic.ts
DomElementObjectPool jsdoc
[mirror_xterm.js.git] / src / utils / Generic.ts
CommitLineData
d426c998 1/**
1d300911 2 * Generic utilities module with methods that can be helpful at different parts of the code base.
d426c998 3 * @module xterm/utils/Generic
1d300911 4 * @license MIT
d426c998
PK
5 */
6
bc70b3b3
PK
7/**
8 * Return if the given array contains the given element
9 * @param {Array} array The array to search for the given element.
10 * @param {Object} el The element to look for into the array
11 */
3e1a6071 12export function contains(arr: any[], el: any) {
bc70b3b3 13 return arr.indexOf(el) >= 0;
d426c998 14};