diff options
| author | ST-DDT <[email protected]> | 2023-11-13 09:20:17 +0100 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-11-13 08:20:17 +0000 |
| commit | a747854d6b5d4db5c02ff344b8abb322c6ceac99 (patch) | |
| tree | dd1b53816d9c6ba3986ed85b001dbdcd68111f4b /src/modules/string | |
| parent | 7ce8c285cb5b2d13e95a17be78ecbd52f3c7d9db (diff) | |
| download | faker-a747854d6b5d4db5c02ff344b8abb322c6ceac99.tar.xz faker-a747854d6b5d4db5c02ff344b8abb322c6ceac99.zip | |
test(docs): ensure defaults are consistent (#2177)
Diffstat (limited to 'src/modules/string')
| -rw-r--r-- | src/modules/string/index.ts | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/modules/string/index.ts b/src/modules/string/index.ts index 923c5286..e841e29d 100644 --- a/src/modules/string/index.ts +++ b/src/modules/string/index.ts @@ -351,6 +351,11 @@ export class StringModule extends SimpleModuleBase { */ binary( options: { + /** + * The number or range of characters to generate after the prefix. + * + * @default 1 + */ length?: | number | { @@ -363,6 +368,11 @@ export class StringModule extends SimpleModuleBase { */ max: number; }; + /** + * Prefix for the generated number. + * + * @default '0b' + */ prefix?: string; } = {} ): string { @@ -393,6 +403,11 @@ export class StringModule extends SimpleModuleBase { */ octal( options: { + /** + * The number or range of characters to generate after the prefix. + * + * @default 1 + */ length?: | number | { @@ -405,6 +420,11 @@ export class StringModule extends SimpleModuleBase { */ max: number; }; + /** + * Prefix for the generated number. + * + * @default '0o' + */ prefix?: string; } = {} ): string { |
