Extended by
Constructors
new Wordlist()
Parameters
| Parameter | Type |
|---|---|
locale | string |
Returns
Wordlist
Source
wordlists/wordlist.ts:20Methods
getWord()
Parameters
| Parameter | Type |
|---|---|
index | number |
Returns
string
Source
wordlists/wordlist.ts:54getWordIndex()
Parameters
| Parameter | Type |
|---|---|
word | string |
Returns
number
Source
wordlists/wordlist.ts:61join()
words into a phrase.
By default, words are joined by a single space.
Parameters
| Parameter | Type | Description |
|---|---|---|
words | string[] | The words to join. |
Returns
string
The joined phrase.
Source
wordlists/wordlist.ts:45split()
phrase into individual words.
By default, phrase is split using any sequences of white-space as defined by regular expressions (i.e.
/\s+/).
Parameters
| Parameter | Type | Description |
|---|---|---|
phrase | string | The phrase to split. |
Returns
string[]
The split words in the phrase.
