Installation
npm install --save @types/weighted-random-object
Summary
This package contains type definitions for weighted-random-object (https://github.com/misund/weighted-random-object).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/weighted-random-object.
index.d.ts
// TypeScript Version: 2.7
interface Weighted {
weight: number;
}
declare function weightedRandomObject<T extends Weighted>(objects: readonly T[]): T;
export = weightedRandomObject;
Additional Details
- Last updated: Mon, 20 Nov 2023 23:36:24 GMT
- Dependencies: none
Credits
These definitions were written by mike castleman.