Skip to content

shuffle

shuffle<T>(items): T[]

Defined in: src/global/collections.ts:147

A shuffled copy. The input is untouched.

T

Collection<T>

T[]

shuffle([1, 2, 3, 4, 5]); // [ 3, 1, 5, 2, 4 ]