Skip to content

Commit

Permalink
chore: reword to elements (#2049)
Browse files Browse the repository at this point in the history
  • Loading branch information
Shinigami92 authored Apr 15, 2023
1 parent 5aa51d8 commit 5e421b0
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/modules/helpers/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -554,7 +554,7 @@ export class HelpersModule {
/**
* Takes an array and randomizes it in place then returns it.
*
* @template T The type of the entries to shuffle.
* @template T The type of the elements to shuffle.
* @param list The array to shuffle.
* @param options The options to use when shuffling.
* @param options.inplace Whether to shuffle the array in place or return a new array. Defaults to `false`.
Expand All @@ -578,7 +578,7 @@ export class HelpersModule {
/**
* Returns a randomized version of the array.
*
* @template T The type of the entries to shuffle.
* @template T The type of the elements to shuffle.
* @param list The array to shuffle.
* @param options The options to use when shuffling.
* @param options.inplace Whether to shuffle the array in place or return a new array. Defaults to `false`.
Expand All @@ -603,7 +603,7 @@ export class HelpersModule {
/**
* Returns a randomized version of the array.
*
* @template T The type of the entries to shuffle.
* @template T The type of the elements to shuffle.
* @param list The array to shuffle.
* @param options The options to use when shuffling.
* @param options.inplace Whether to shuffle the array in place or return a new array. Defaults to `false`.
Expand Down Expand Up @@ -646,7 +646,7 @@ export class HelpersModule {
* and outputs a unique array of strings based on that source.
* This method does not store the unique state between invocations.
*
* @template T The type of the entries.
* @template T The type of the elements.
* @param source The strings to choose from or a function that generates a string.
* @param length The number of elements to generate.
*
Expand Down Expand Up @@ -785,7 +785,7 @@ export class HelpersModule {
/**
* Returns random element from the given array.
*
* @template T The type of the entries to pick from.
* @template T The type of the elements to pick from.
* @param array Array to pick the value from.
*
* @example
Expand All @@ -812,7 +812,7 @@ export class HelpersModule {
*
* For example, if there are two values A and B, with weights 1 and 2 respectively, then the probability of picking A is 1/3 and the probability of picking B is 2/3.
*
* @template T The type of the entries to pick from.
* @template T The type of the elements to pick from.
* @param array Array to pick the value from.
* @param array[].weight The weight of the value.
* @param array[].value The value to pick.
Expand Down Expand Up @@ -867,7 +867,7 @@ export class HelpersModule {
/**
* Returns a subset with random elements of the given array in random order.
*
* @template T The type of the entries to pick from.
* @template T The type of the elements to pick from.
* @param array Array to pick the value from.
* @param count Number or range of elements to pick.
* When not provided, random number of elements will be picked.
Expand Down

0 comments on commit 5e421b0

Please sign in to comment.