MCPcopy
hub / github.com/chartjs/Chart.js / _arrayUnique

Function _arrayUnique

src/helpers/helpers.collection.ts:184–192  ·  src/helpers/helpers.collection.ts::_arrayUnique
(items: T[])

Source from the content-addressed store, hash-verified

182 * @param items
183 */
184export function _arrayUnique<T>(items: T[]) {
185 const set = new Set<T>(items);
186
187 if (set.size === items.length) {
188 return items;
189 }
190
191 return Array.from(set);
192}

Callers 2

getAllScaleValuesFunction · 0.85
normalizeMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected