pandemonium
Version:
Typical random-related functions for JavaScript.
15 lines (10 loc) • 359 B
TypeScript
import {RNGFunction} from './types';
type ShuffleInPlaceFunction<T> = (array: Array<T>) => void;
declare const shuffleInPlace: {
<T>(array: Array<T>): void;
createShuffleInPlace<T>(rng: RNGFunction): ShuffleInPlaceFunction<T>;
};
export function createShuffleInPlace<T>(
rng: RNGFunction
): ShuffleInPlaceFunction<T>;
export default shuffleInPlace;