textConvert
    Preparing search index...

    Function slugify

    • Convert text into a URL-safe slug: lowercase, punctuation stripped, separators collapsed to a single "-", and accented characters normalized to their plain-ASCII equivalents.

      Parameters

      • text: string

        Text to slugify.

      Returns string

      A lowercase, hyphen-separated, URL-safe slug.

      slugify('Hello, World! 100% Awesome'); // 'hello-world-100-awesome'
      slugify(' Multiple Spaces '); // 'multiple-spaces'