UNPKG

@fivem-ts/shared

Version:

FiveM Typescript wrapper shared part

11 lines (10 loc) 361 B
/** * Returns a random entry from the given enum type. * * @template T * * @param {object} enumType - The enum type from which to select a random entry. * * @return {[keyof T, T[keyof T]]} - An array containing the random key-value pair from the enum. */ export declare function getRandomEnumEntry<T extends object>(enumType: T): [keyof T, T[keyof T]];