Helpers for generating consistent, URL-friendly slugs across PhoenixKit.
Provides functions to slugify arbitrary text, enforce separator rules, and ensure uniqueness by delegating existence checks via callback.
Summary
Functions
Ensures the provided slug is unique by calling exists_fun.
Converts the given text into a slug.
Functions
Ensures the provided slug is unique by calling exists_fun.
exists_fun should return truthy when the slug is already taken.
Converts the given text into a slug.
Options:
:separator- character used between words (defaults to "-")
Returns an empty string when the input is blank or cannot be converted.