From 7bc4a099558318c690d0101dc4765c08dee2c840 Mon Sep 17 00:00:00 2001 From: DivisionByZero Date: Sun, 29 Jan 2023 17:28:13 +0100 Subject: refactor(string): rename `special` to `symbol` (#1789) --- src/modules/string/index.ts | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'src/modules/string') diff --git a/src/modules/string/index.ts b/src/modules/string/index.ts index 6184c043..8f62788a 100644 --- a/src/modules/string/index.ts +++ b/src/modules/string/index.ts @@ -740,20 +740,23 @@ export class StringModule { } /** - * Returns a string containing only special characters. + * Returns a string containing only special characters from the following list: + * ```txt + * ! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~ + * ``` * * @param length Length of the generated string. Defaults to `1`. * @param length.min The minimum number of special characters to generate. * @param length.max The maximum number of special characters to generate. * * @example - * faker.string.special() // '$' - * faker.string.special(5) // '#*!.~' - * faker.string.special({ min: 5, max: 10 }) // ')|@*>^+' + * faker.string.symbol() // '$' + * faker.string.symbol(5) // '#*!.~' + * faker.string.symbol({ min: 5, max: 10 }) // ')|@*>^+' * * @since 8.0.0 */ - special( + symbol( length: | number | { -- cgit v1.2.3