faker.utils.text

Module Contents

Functions

slugify(→ str)

Converts to lowercase, removes non-word characters (alphanumerics and

Attributes

_re_pattern

_re_pattern_allow_dots

_re_spaces

faker.utils.text._re_pattern: Pattern
faker.utils.text._re_pattern_allow_dots: Pattern
faker.utils.text._re_spaces: Pattern
faker.utils.text.slugify(value: str, allow_dots: bool = False, allow_unicode: bool = False) str

Converts to lowercase, removes non-word characters (alphanumerics and underscores) and converts spaces to hyphens. Also strips leading and trailing whitespace. Modified to optionally allow dots.

Adapted from Django 1.9